Open
Description
Bug description
# This module is named "gzip".
#!/usr/bin/python3
"""Test"""
import gzip
gzip.main()
Configuration
No response
Command used
pylint gzip
Pylint output
************* Module gzip
gzip:5:0: W0406: Module import itself (import-self)
gzip:7:0: E1101: Module 'gzip' has no 'main' member (no-member)
Expected behavior
pylint shouldn't think a program named "foo" can be imported as "foo" when it doesn't have a .py extension
Pylint version
pylint 2.14.5
astroid 2.11.7
Python 3.9.2 (default, Feb 28 2021, 17:03:44)
[GCC 10.2.1 20210110]
OS / Environment
Linux
Additional dependencies
No response