I am trying to use PyScripter however I can import certain modules however I am unable to successfully import the arcpy library.
I have tried configuring the Environment Variables PYTHONPATH without any success. I know I'm missing something with the the correct path to the python executable.
Thanks for your assistance in advance
The Desktop10.8pth references the following
C:\Program Files (x86)\ArcGIS\Desktop10.8\bin
C:\Program Files (x86)\ArcGIS\Desktop10.8\ArcPy
C:\Program Files (x86)\ArcGIS\Desktop10.8\ArcToolBox\Scripts
Pyscripter is returning the following
import arcpy
ModuleNotFoundError: No module named 'arcpy'
IDLE Shell is returning Traceback (most recent call last): File "<pyshell#0>", line 1, in import arcpy ModuleNotFoundError: No module named 'arcpy'
The message
ModuleNotFoundError: No module named 'arcpy'comes from whatever pythonx.y you are running. Do you have more than one python installed on your system? If so, the common error is to install something for one python and try to import it with another.What you call the 2.7 structure shows
Python39-32. Does arcpy run with that version?If you are trying to run arcpy with python x.y, the pythonx.y directory
Lib/site-packages/must contain the arcpy package or a.pthfile pointing to its location. IsDesktop10.8ptha typo version ofDesktop10.8.pth. If so, then one of the directories, most likely the one ending inArcPymust contain either anarcpypackage directory or anarcpy.pyfile.