Skip to content

Invocation as python module python -m ruff does not work properly #2520

@trottomv

Description

@trottomv

When ruff is installed on system without virtualenv or in a different path than the default, the invocation as a python module does not work, and a sys exit occurs without errors printed on the console:

$ pip install ruff
or
$ pip install --user --no-cache ruff

$ ruff -V
ruff 0.0.238
$ python -m ruff check -v .
$ ruff check -v .
...
[2023-02-03][10:15:35][ruff::rules::isort::categorize][DEBUG] Categorized 'json' as StandardLibrary (KnownStandardL
[2023-02-03][10:15:35][ruff::rules::isort::categorize][DEBUG] Categorized 'django' as ThirdParty (KnownThirdParty)
[2023-02-03][10:15:35][ruff::rules::isort::categorize][DEBUG] Categorized 'django_drf_filepond' as ThirdParty (NoMa
[2023-02-03][10:15:35][ruff::rules::isort::categorize][DEBUG] Categorized 'django' as ThirdParty (KnownThirdParty)
[2023-02-03][10:15:35][ruff::rules::isort::categorize][DEBUG] Categorized 'django' as ThirdParty (KnownThirdParty)
...
$ find / -name "ruff"
/home/trotto/.local/lib/python3.11/site-packages/ruff
/home/trotto/.local/bin/ruff

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions