Closed sandeepgadhwal closed 7 years ago
Is your ArcGIS version 64bit?
I see that you are using arcgis 10.5. Archook has never been tested against this version (it must be the latest?), so it is feasible there have been changes to directory paths.
Can you confirm that your ArcGIS directory (C:\Program Files (x86)\ArcGIS\Desktop10.5) contains a bin
folder and bin64
folder?
Yes i have installed 64 bit geoprocessing and my argis folder contains bin and bin64.
On 30-May-2017 1:39 PM, "James Ramm" notifications@github.com wrote:
I see that you are using arcgis 10.5. Archook has never been tested against this version (it must be the latest?), so it is feasible there have been changes to directory paths. Can you confirm that your ArcGIS directory (C:\Program Files (x86)\ArcGIS\Desktop10.5) contains a bin folder and bin64 folder?
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/JamesRamm/archook/issues/11#issuecomment-304805982, or mute the thread https://github.com/notifications/unsubscribe-auth/ARpk2LT22lrq46-X29RS-oeOg3Qs676Yks5r-87KgaJpZM4NoqrT .
I am new to this python scripting but if I can help you in anyway please ask me as this tool archook really makes life easy and it would be great if it supports the latest version.
On 30-May-2017 1:51 PM, "Sandeep Kumar" sandeepgadhwal1@gmail.com wrote:
Yes i have installed 64 bit geoprocessing and my argis folder contains bin and bin64.
On 30-May-2017 1:39 PM, "James Ramm" notifications@github.com wrote:
I see that you are using arcgis 10.5. Archook has never been tested against this version (it must be the latest?), so it is feasible there have been changes to directory paths. Can you confirm that your ArcGIS directory (C:\Program Files (x86)\ArcGIS\Desktop10.5) contains a bin folder and bin64 folder?
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/JamesRamm/archook/issues/11#issuecomment-304805982, or mute the thread https://github.com/notifications/unsubscribe-auth/ARpk2LT22lrq46-X29RS-oeOg3Qs676Yks5r-87KgaJpZM4NoqrT .
_base
is a pyd (a compiled extension module), so an ImportError would typically be generated by either of these:
_base
was not added to the path.Is _base
in the bin64
directory?
Can you do a print(sys.path)
after calling get_arcpy
and paste the contents here?
import archook archook.get_arcpy() import sys print(sys.path) ['', 'C:\Program Files (x86)\ArcGIS\Desktop10.5\arcpy', 'C:\ProgramData\Anaconda3\python36.zip', 'C:\ProgramData\Anaconda3\DLLs', 'C:\ProgramData\Anaconda3\lib', 'C:\ProgramData\Anaconda3', 'C:\ProgramData\Anaconda3\lib\site-packages', 'C:\ProgramData\Anaconda3\lib\site-packages\Sphinx-1.5.1-py3.6.egg', 'C:\ProgramData\Anaconda3\lib\site-packages\win32', 'C:\ProgramData\Anaconda3\lib\site-packages\win32\lib', 'C:\ProgramData\Anaconda3\lib\site-packages\Pythonwin', 'C:\ProgramData\Anaconda3\lib\site-packages\setuptools-27.2.0-py3.6.egg', 'C:\Program Files (x86)\ArcGIS\Desktop10.5\arcpy', 'C:\Program Files (x86)\ArcGIS\Desktop10.5\bin64', 'C:\Program Files (x86)\ArcGIS\Desktop10.5\ArcToolbox\Scripts']
https://mailtrack.io/ Sent with Mailtrack https://mailtrack.io/install?source=signature&lang=en&referral=sandeepgadhwal1@gmail.com&idSignature=22
On Tue, May 30, 2017 at 1:58 PM, James Ramm notifications@github.com wrote:
_base is a pyd (a compiled extension module), so an ImportError would typically be generated by either of these:
- mismatch between the bitness of the pyd, arcgis, python (64bit vs 32bit)
- The directory containing _base was not added to the path.
Is _base in the bin64 directory? Can you do a print(sys.path) after calling get_arcpy and paste the contents here?
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/JamesRamm/archook/issues/11#issuecomment-304809924, or mute the thread https://github.com/notifications/unsubscribe-auth/ARpk2Kbdz43VFxuch8wIQeMkpsYtHZuMks5r-9MjgaJpZM4NoqrT .
I can see that the bin64
directory is correctly added to the path, as is the arcpy
directory.
Can you confirm that either
C:/Program Files(x86)/ArcGIS/Desktop10.5/bin64
or
C:/Program Files (x86)/ArcGIS/Desktop10.5/arcpy
contains a _base.pyd
file?
C:\Program Files (x86)\ArcGIS\Desktop10.5\arcpy\arcpy contains a _base.py file
As far as I know, ArcGIS 10.5 for desktop still uses python 2.x, so there is a chance this causes problems. Try creating a new conda environment for python 2 and importing archook into that:
conda create -n py2 python=2.7
source activate py2
pip install archook numpy==1.9.3
P.S. github doesnt show images attached to emails
i am able to import arcpy in anaconda 2.7 32 bit.
https://mailtrack.io/ Sent with Mailtrack https://mailtrack.io/install?source=signature&lang=en&referral=sandeepgadhwal1@gmail.com&idSignature=22
On Tue, May 30, 2017 at 2:22 PM, James Ramm notifications@github.com wrote:
As far as I know, ArcGIS 10.5 for desktop still uses python 2.x, so there is a chance this causes problems. Try creating a new conda environment for python 2 and importing archook into that:
conda create -n py2 python=2.7 source activate py2 pip install archook numpy==1.9.3
P.S. github doesnt show images attached to emails
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/JamesRamm/archook/issues/11#issuecomment-304815559, or mute the thread https://github.com/notifications/unsubscribe-auth/ARpk2J9AfRS2HJpHeKXOAxjwj7NiV0fqks5r-9jUgaJpZM4NoqrT .
(C:\ProgramData\Anaconda2) C:\Users\sandyjones>python Python 2.7.13 |Anaconda 4.3.1 (32-bit)| (default, Dec 19 2016, 13:36:02) [MSC v.1500 32 bit (Intel)] on win32 Type "help", "copyright", "credits" or "license" for more information. Anaconda is brought to you by Continuum Analytics. Please check out: http://continuum.io/thanks and https://anaconda.org
import archook archook.get_arcpy() import arcpy arcpy <module 'arcpy' from 'C:\Program Files (x86)\ArcGIS\Desktop10.5\arcpy\arcpy__init__.pyc'>
https://mailtrack.io/ Sent with Mailtrack https://mailtrack.io/install?source=signature&lang=en&referral=sandeepgadhwal1@gmail.com&idSignature=22
On Tue, May 30, 2017 at 2:23 PM, Sandeep Kumar sandeepgadhwal1@gmail.com wrote:
i am able to import arcpy in anaconda 2.7 32 bit.
https://mailtrack.io/ Sent with Mailtrack https://mailtrack.io/install?source=signature&lang=en&referral=sandeepgadhwal1@gmail.com&idSignature=22
On Tue, May 30, 2017 at 2:22 PM, James Ramm notifications@github.com wrote:
As far as I know, ArcGIS 10.5 for desktop still uses python 2.x, so there is a chance this causes problems. Try creating a new conda environment for python 2 and importing archook into that:
conda create -n py2 python=2.7 source activate py2 pip install archook numpy==1.9.3
P.S. github doesnt show images attached to emails
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/JamesRamm/archook/issues/11#issuecomment-304815559, or mute the thread https://github.com/notifications/unsubscribe-auth/ARpk2J9AfRS2HJpHeKXOAxjwj7NiV0fqks5r-9jUgaJpZM4NoqrT .
great
i have 64bit python installed by arcgis in C:\Python27\ArcGISx6410.5 when i import arcpy there i get this error.
Such errors are often caused by a mismatch in bitness. Since this appears to be a problem with the ArcGIS installation and not archook (you can create import problems without archook) then I suggest posting on the ArcGIS support forum?
Archook seems to be working correctly when you match up the correct python version, so I'll close this.
okay so can i import arcpy in 64bit windows or not.
Evidently in your current setup, you cant. Whether you are supposed to be able to is a question for the ArcGIS support (maybe there is a problem with your installation).
thanks james.
this is the error which i am getting