Pillow not importing in VSCode on mac with Python 3.10.5
I installed pillow correctly. But when I try to import Pillow in VScode it says module not found. But if I change the interpreter from 3.10.5 to 3.9.13 the error disappears.
The following is how I imported PIL
from PIL import Image
Is this a bug or am I doing something wrong?
It sounds like Pillow is installed in Python 3.9, but not Python 3.10.
Could you provide some detail on how you installed Pillow?
If you installed Pillow with pip install Pillow, then that does not install Pillow for all versions of Python, only one. At https://pillow.readthedocs.io/en/stable/installation.html#basic-installation, we suggest that you try installing Pillow by using python3 -m pip install --upgrade Pillow, so that you know that Pillow is installed for the version that you plan to use, rather than whatever version pip is connected to. So python3.10 -m pip install --upgrade Pillow might fix your problem.
To answer your question, no, I don't expect this to be a bug. Simply that Pillow has not been installed in the specific version you're using.
Closing this issue as no feedback has been received.