PyPI / virtualenv / 21.14.9

virtualenv 21.14.9

Source
https://github.com/pypa/virtualenv
Tag scanned
21.14.9
Compared with
21.14.8 (0 signals introduced since)
Files
208 scanned, 33 skipped (binary, oversized, or unrecognised)
Signals
0 critical · 0 warn · 14 info
Scan time
9.3 s
LLM review
Reviewed by claude-haiku-5-5 (Anthropic): 10 of 10 warn and critical signals; 10 demoted to info.
Disclude version
4.0.0
Scanned (UTC)
2026-10-18 09:41

Signals

Ordered by severity, then signals introduced in this release. Hidden characters are shown as ⟨U+…⟩.

  1. info critical → info by review dynamic-import docs/render_cli.py:40:34

    `__import__` called on a non-literal expression (ast pass, confidence 0.70)

            module_name, attr_name = self.options["module"], self.options["func"]
            parser_creator = getattr(__import__(module_name, fromlist=[attr_name]), attr_name)
            core_result = parse_parser(parser_creator())
    likely benign LLM, confidence 0.85 Dynamic import of a parser-creator module named in the docs options, used to render CLI docs.
    Reasoning

    The code resolves a module and attribute name from configured options (sphinx-argparse style) and calls the parser factory. This is a documentation build helper, and the module name comes from the docs configuration rather than untrusted input. The dynamic import is expected for this tool.

  2. info critical → info by review dynamic-import docs/render_cli.py:236:20

    `__import__` called on a non-literal expression (ast pass, confidence 0.70)

        of_class = of_type.split(".")
        data = getattr(__import__(".".join(of_class[:-1]), fromlist=[of_class[-1]]), of_class[-1])
        return [n.literal("", text=",".join(data))], []
    likely benign LLM, confidence 0.85 Dynamic import of a dotted class path in a docs rendering helper.
    Reasoning

    The import path is split from a dotted type string in the documentation renderer and used to fetch a class's data for display. It is the same documentation-tooling pattern as the other finding in this file, and no network or untrusted input source is shown.

  3. info warn → info by review dynamic-execution docs/tutorial/getting-started.rst:102:21

    [embedded bash] command name is a variable (`$which`) not set in this file — the caller or environment decides what runs (ast pass, confidence 0.70)

            (myproject) $ which python
            /home/user/myproject/bin/python
    likely benign LLM, confidence 0.90 Tutorial shell prompt example with a variable-like token in documentation text.
    Reasoning

    This is a reStructuredText tutorial showing an interactive session. The `$which` token is a shell prompt example, and the following lines are sample output, not executed code. The flag is a parser artifact.

  4. info critical → info by review path-command-shadow docs/tutorial/getting-started.rst:109:23

    [embedded bash] redirect writes to `python` — filename matches a system command (PATH hijack setup) (ast pass, confidence 0.88)

            (myproject) PS> where.exe python
            C:\Users\user\myproject\Scripts\python.exe
    likely benign LLM, confidence 0.85 Windows PowerShell tutorial showing where.exe output for the Python executable.
    Reasoning

    The snippet is documentation output from `where.exe python` in a PowerShell example. The 'redirect' and 'PATH hijack' reading comes from misparsing the Windows output path as a redirect target. Nothing in the snippet writes a file or changes PATH.

  5. info warn → info by review obfuscated-command-name docs/tutorial/getting-started.rst:110:9

    [embedded bash] command name contains 5 backslash-escape sequences — hiding the true command (ast pass, confidence 0.85)

            (myproject) PS> where.exe python
            C:\Users\user\myproject\Scripts\python.exe
    likely benign LLM, confidence 0.90 Windows path separators in a documented command output were misread as escape obfuscation.
    Reasoning

    The flagged 'command name' is a Windows path with backslash separators, such as C:\Users\...\python.exe, in a documentation example. Backslashes are path separators here, not obfuscation of a command.

  6. info warn → info by review obfuscated-command-name docs/tutorial/getting-started.rst:117:9

    [embedded bash] command name contains 5 backslash-escape sequences — hiding the true command (ast pass, confidence 0.85)

            (myproject) C:\> where.exe python
            C:\Users\user\myproject\Scripts\python.exe
    likely benign LLM, confidence 0.90 Windows path in a documented cmd example flagged as backslash-escaped command name.
    Reasoning

    This is the same pattern as the earlier finding: a Windows path in a `where.exe python` sample output within a cmd tutorial. The backslashes are normal path separators.

  7. info warn → info by review dynamic-execution docs/tutorial/getting-started.rst:127:17

    [embedded bash] command name is a variable (`$pip`) not set in this file — the caller or environment decides what runs (ast pass, confidence 0.70)

        (myproject) $ pip install requests
        Collecting requests
          Using cached requests-2.32.3-py3-none-any.whl (64 kB)
    likely benign LLM, confidence 0.90 Tutorial example running pip install, with a prompt token that the scanner read as a variable command name.
    Reasoning

    The `$pip` token is a shell prompt example in a tutorial, followed by sample install output. It is documentation, not executed code, and the command is standard pip usage.

  8. info warn → info by review dynamic-execution docs/tutorial/getting-started.rst:137:17

    [embedded bash] command name is a variable (`$python`) not set in this file — the caller or environment decides what runs (ast pass, confidence 0.70)

        (myproject) $ python -c "import requests; print(requests.__file__)"
        /home/user/myproject/lib/python3.13/site-packages/requests/__init__.py
    likely benign LLM, confidence 0.90 Tutorial example running python -c to print the requests package location.
    Reasoning

    The `$python` token is a shell prompt in a tutorial showing a requests import check. The sample output is a normal site-packages path. This is documentation text with no hidden execution.

  9. info warn → info by review obfuscated-command-name docs/tutorial/getting-started.rst:176:9

    [embedded bash] command name contains 3 backslash-escape sequences — hiding the true command (ast pass, confidence 0.85)

            PS> .\myproject\Scripts\python.exe -c "import sys; print(sys.prefix)"
            C:\Users\user\myproject
    
            PS> .\myproject\Scripts\pip.exe install httpx
    likely benign LLM, confidence 0.90 Relative Windows venv path in a tutorial example flagged as obfuscated command name.
    Reasoning

    The flagged command is a relative Windows path with backslash separators to a venv python.exe, shown in a documentation example. The backslashes are path separators, not an escape-based concealment technique.

  10. info warn → info by review obfuscated-command-name docs/tutorial/getting-started.rst:185:9

    [embedded bash] command name contains 3 backslash-escape sequences — hiding the true command (ast pass, confidence 0.85)

            C:\> .\myproject\Scripts\python.exe -c "import sys; print(sys.prefix)"
            C:\Users\user\myproject
    
            C:\> .\myproject\Scripts\pip.exe install httpx
    likely benign LLM, confidence 0.90 Relative Windows venv path in a cmd tutorial example flagged as obfuscated command name.
    Reasoning

    This is the same relative Windows venv path pattern in a cmd-style tutorial example. Backslashes are normal path separators and the content is ordinary venv usage.

  11. info unicode-homoglyph tests/conftest.py:310:47

    identifier `èрт` contains homoglyph candidates: р (0440)→p (in string/comment) (raw pass, confidence 0.35)

        # in PowerShell paths
        base = "'\";&&e-$ !%`|>__VIRTUAL_NAME__[1]èрт🚒♞中片-j"
        if IS_WIN:
            # NTFS path components cannot contain any of these, regardless of where they sit in the string
  12. info unicode-mixed-script tests/conftest.py:310:47

    identifier `èрт` mixes scripts: Latin + Cyrillic (in string/comment) (raw pass, confidence 0.40)

        # in PowerShell paths
        base = "'\";&&e-$ !%`|>__VIRTUAL_NAME__[1]èрт🚒♞中片-j"
        if IS_WIN:
            # NTFS path components cannot contain any of these, regardless of where they sit in the string
  13. identifier `èрт` contains homoglyph candidates: р (0440)→p (in string/comment) (raw pass, confidence 0.35)

        """Exclude ampersands, which batch activation does not support in paths."""
        base = "'\";e-$ èрт🚒♞中片-j"
        if IS_WIN:
            base = base.replace('"', "").replace(";", "")
  14. info unicode-mixed-script tests/unit/activation/test_batch.py:27:21

    identifier `èрт` mixes scripts: Latin + Cyrillic (in string/comment) (raw pass, confidence 0.40)

        """Exclude ampersands, which batch activation does not support in paths."""
        base = "'\";e-$ èрт🚒♞中片-j"
        if IS_WIN:
            base = base.replace('"', "").replace(";", "")

Reproduce This Scan

Run disclude locally to verify. Add --format sarif for SARIF output. Add --llm (with an API key in the environment) to include the LLM review.

cargo install disclude --version 4.0.0
git clone https://github.com/pypa/virtualenv virtualenv && cd virtualenv
git checkout 21.14.9
disclude scan --severity info --diff 21.14.8 .