[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#1121404: marked as done (pylint-django in trixie is broken)



Your message dated Tue, 25 Nov 2025 22:06:04 +0000
with message-id <6926284c8ea77_644d0c23ba@godard.mail>
and subject line Bug#1121404 fixed in pylint-django
has caused the Debian Bug report #1121404,
regarding pylint-django in trixie is broken
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact owner@bugs.debian.org
immediately.)


-- 
1121404: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1121404
Debian Bug Tracking System
Contact owner@bugs.debian.org with problems
--- Begin Message ---
Source: pylint-django
Version: 2.0.13-5
Severity: grave
Tags: patch, trixie
Justification: renders package unusable
X-Debbugs-Cc: igo95862@yandex.ru

Hi,

Because of a new astroid package, pylint-django is completely broken on
trixie. See pylint_django/plugin.py:

    try:
        # pylint: disable=import-outside-toplevel
        from pylint_django.augmentations import apply_augmentations
        apply_augmentations(linter)
    except ImportError:
        # probably trying to execute pylint_django when Django isn't installed
        # in this case the django-not-installed checker will kick-in
        pass

This code is supposed to catch the absence of Django, but also catches
and silences the incorrect import in pylint_django/augmentations/__init__.py:

    from astroid.scoped_nodes import ClassDef as ScopedClass, Module

In the astroid version shipped in trixie, this import is supposed to
look like:

    from astroid.nodes.scoped_nodes import ClassDef as ScopedClass, Module

This can be tested by running the following:

    $ python3 -m pylint_django.augmentations
    Traceback (most recent call last):
      File "<frozen runpy>", line 189, in _run_module_as_main
      File "<frozen runpy>", line 148, in _get_module_details
      File "<frozen runpy>", line 112, in _get_module_details
      File "/usr/lib/python3/dist-packages/pylint_django/augmentations/__init__.py", line 9, in <module>
        from astroid.scoped_nodes import ClassDef as ScopedClass, Module
    ModuleNotFoundError: No module named 'astroid.scoped_nodes'

The expected output in the absence of Django:

    $ python3 -m pylint_django.augmentations
    Traceback (most recent call last):
      File "<frozen runpy>", line 189, in _run_module_as_main
      File "<frozen runpy>", line 148, in _get_module_details
      File "<frozen runpy>", line 112, in _get_module_details
      File "/usr/lib/python3/dist-packages/pylint_django/augmentations/__init__.py", line 12, in <module>
        from django import VERSION as django_version
    ModuleNotFoundError: No module named 'django'

I’m pushing a patch fixing this to the debian/trixie branch in the Git
repository.

-- 
Cheers,
  Andrej

--- End Message ---
--- Begin Message ---
Hello,

Bug #1121404 in pylint-django reported by you has been fixed in the Git repository.
You can see the commit message below and you can check the diff of the fix at:

https://salsa.debian.org/python-team/packages/pylint-django/-/commit/7bedcbf7dd90bb44af98d4362910b35f6a4d29c3

------------------------------------------------------------------------
Fix scoped_nodes import

Closes: #1121404
------------------------------------------------------------------------

(this message was generated automatically)
-- 
Greetings

https://bugs.debian.org/1121404

--- End Message ---

Reply to: