[MacPorts] #74392: py314-pylint @4.0.7_0 throws ast_walker exceptions
MacPorts
noreply at macports.org
Wed Sep 2 01:46:34 UTC 2026
#74392: py314-pylint @4.0.7_0 throws ast_walker exceptions
--------------------+-----------------------
Reporter: saj | Owner: stromnov
Type: defect | Status: assigned
Priority: Normal | Milestone:
Component: ports | Version: 2.12.6
Keywords: | Port: py-pylint
--------------------+-----------------------
repro:
{{{
% cat testscript
#!/usr/bin/env python3
import os
}}}
{{{
% pylint testscript
************* Module testscript
testscript:1:0: C0114: Missing module docstring (missing-module-docstring)
Exception on node <Import l.3 at 0x106ed0440> in file '/Users/saj/s/stash
/shstash-JPfeHeHQ/testscript'
Traceback (most recent call last):
File
"/opt/local/Library/Frameworks/Python.framework/Versions/3.14/lib/python3.14
/site-packages/pylint/utils/ast_walker.py", line 87, in walk
callback(astroid)
~~~~~~~~^^^^^^^^^
File
"/opt/local/Library/Frameworks/Python.framework/Versions/3.14/lib/python3.14
/site-packages/pylint/checkers/variables.py", line 2139, in visit_import
module = next(_infer_name_module(node, parts[0]))
~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^
File
"/opt/local/Library/Frameworks/Python.framework/Versions/3.14/lib/python3.14
/site-packages/pylint/checkers/variables.py", line 220, in
_infer_name_module
return node.infer(context, asname=False) # type: ignore[no-any-
return]
~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^
TypeError: NodeNG.infer() got an unexpected keyword argument 'asname'
testscript:1:0: F0002: testscript: Fatal error while checking
'testscript'. Please open an issue in our bug tracker so we address this.
There is a pre-filled template that you can use in
'/Users/saj/Library/Caches/pylint/pylint-crash-2026-09-02-11-38-50.txt'.
(astroid-error)
}}}
{{{
% pylint --version
pylint 4.0.7
astroid 4.3.1
Python 3.14.7 (main, Aug 8 2026, 17:19:07) [Clang 17.0.0
(clang-1700.0.13.5)]
}}}
I don't think this is an upstream bug. Works OK with pylint from PyPI.
{{{
(venv) % venv/bin/pylint testscript
************* Module testscript
testscript:1:0: C0114: Missing module docstring (missing-module-docstring)
testscript:3:0: W0611: Unused import os (unused-import)
------------------------------------------------------------------
Your code has been rated at 0.00/10 (previous run: 0.00/10, +0.00)
(venv) % venv/bin/pylint --version
pylint 4.0.7
astroid 4.0.4
Python 3.14.7 (main, Aug 8 2026, 17:19:07) [Clang 17.0.0
(clang-1700.0.13.5)]
}}}
{{{
% port echo active | awk '$1 ~ /astroid|pylint|python/'
py314-astroid @4.3.1_0
py314-pylint @4.0.7_0
pylint_select @0.1_2
python2_select @0.1_0
python3_select @0.1_0
python3_select-313 @0.1_1
python3_select-314 @0.1_1
python27 @2.7.18_10+lto+optimizations
python313 @3.13.15_0+lto+optimizations
python314 @3.14.7_0+lto+optimizations
python_select @0.3_10
python_select-313 @0.3_1
python_select-314 @0.3_1
}}}
--
Ticket URL: <https://trac.macports.org/ticket/74392>
MacPorts <https://www.macports.org/>
Ports system for macOS
More information about the macports-tickets
mailing list