import qgis geoprocessing tools in python os x 10.9.5

المشرف العام

Administrator
طاقم الإدارة
I'd like to use the python bindings from qgis, but in a standalone project.I need the geoprocessing tools for vectors.

I updated QGIS (Wien - 2.8), python (3.4.3), etc.However, it always ends with the following error :

import qgis.core Traceback (most recent call last): File "", line 1, in File "/Applications/QGIS.app/Contents/Resources/python/qgis/init.py", line 26, in import sip ImportError: dlopen(/Applications/QGIS.app/Contents/Resources/python/sip.so, 2): Symbol not found: _PyCObject_Type Referenced from: /Applications/QGIS.app/Contents/Resources/python/sip.so Expected in: flat namespace in /Applications/QGIS.app/Contents/Resources/python/sip.so

I set the following path :export PYTHONPATH=/Applications/QGIS.app/Contents/Resources/python/export DYLD_LIBRARY_PATH=/Applications/QGIS.app/Contents/MacOS/lib/:/Applications/QGIS.app/Contents/Frameworks/

The issue is obviously about SIP, but I truly don't know what to do.The python console inside QGIS is not insulting me when I'm giving it "import qgis.core".So I 'd bet there is something about the versions of SIP, Python "command line" and Python "QGIS command line".

I can't say what... and I'mm really stuck.

I am using miniconda3 for my libraries (rsgislib, gdal, ogr, ...).



أكثر...
 
أعلى