/usr/bin/pylint starts with the line: #! /usr/bin/python3 -sP The -s option tells the Python not to add user site directory to sys.path. This obstructs checking of programs developed by the user. In my opinion the -s option should be removed. Reproducible: Always Steps to Reproduce: 1. select a python library/package name for testing, either na existing one from the output of: pip list --user or install from Pypi any arbitrary one not already present, preferrably small and without dependencies. I'm using a tiny utility "jsonstrip" just as an example: pip install --user jsonstrip 2. create a test.py file containing just the line "import jsonstrip", it is a correct python program albeit completely useless 3. verify that the program runs without errors: python test.py 4. run pylint test.py 5. (cleanup: remove test.py and uninstall jsonstrip) Actual Results: pylint shows (among other lines): Unable to import 'jsonstrip' (import-error) That is not true, see the step #3. Expected Results: pylint should be able to import user-installed packages.
I see this, and I'm not sure what's adding that flag to the script. Does testing with "python3 -m pylint test.py" work?
FYI - https://docs.fedoraproject.org/en-US/packaging-guidelines/Python/#_shebangs
Ah ha, thank you! Update incoming.
FEDORA-2024-19ce931ab4 has been submitted as an update to Fedora 39. https://bodhi.fedoraproject.org/updates/FEDORA-2024-19ce931ab4
FEDORA-2024-19ce931ab4 has been pushed to the Fedora 39 testing repository. Soon you'll be able to install the update with the following command: `sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2024-19ce931ab4` You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2024-19ce931ab4 See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.
FEDORA-2024-19ce931ab4 has been pushed to the Fedora 39 stable repository. If problem still persists, please make note of it in this bug report.