_gdxcc.so issue
Posted: Sat May 12, 2018 4:41 pm
Hi all,
I am trying to set up my machine to use the Python API. I am following along the Tutorial and am having issues running transport1.py script after installing the API and packages. I receive the following message when trying to run the script:
According to the traceback the issue is with opening _PyCLass_Type in _gdxcc.so . I searched on this forum and found an example where a user had a dlopen issue (viewtopic.php?f=10&t=10219&p=23399&hilit=dlopen#p23399). I tried the Xcode command line procedure but am still experiencing the error above.
I am using Python 3.6 from Anaconda and GAMS 25.0 on OX 10.13.4. Is this a bug or is there something I am missing? Thanks in advance,
David Wogan
I am trying to set up my machine to use the Python API. I am following along the Tutorial and am having issues running transport1.py script after installing the API and packages. I receive the following message when trying to run the script:
Code: Select all
Davids-MacBook:python davidwogan$ python transport1.py
Traceback (most recent call last):
File "/Users/davidwogan/anaconda3/lib/python3.6/site-packages/gdxcc.py", line 14, in swig_import_helper
return importlib.import_module(mname)
File "/Users/davidwogan/anaconda3/lib/python3.6/importlib/__init__.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 994, in _gcd_import
File "<frozen importlib._bootstrap>", line 971, in _find_and_load
File "<frozen importlib._bootstrap>", line 955, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 658, in _load_unlocked
File "<frozen importlib._bootstrap>", line 571, in module_from_spec
File "<frozen importlib._bootstrap_external>", line 922, in create_module
File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
ImportError: dlopen(/Users/davidwogan/anaconda3/lib/python3.6/site-packages/_gdxcc.so, 2): Symbol not found: _PyClass_Type
Referenced from: /Applications/GAMS25.0/sysdir/_gdxcc.so
Expected in: flat namespace
in /Applications/GAMS25.0/sysdir/_gdxcc.so
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "transport1.py", line 10, in <module>
from gams import *
File "/Users/davidwogan/anaconda3/lib/python3.6/site-packages/gams/__init__.py", line 8, in <module>
from .workspace import *
File "gams/workspace.py", line 8, in init gams.workspace (workspace.c:20144)
File "gams/database.py", line 2, in init gams.database (database.c:51898)
File "/Users/davidwogan/anaconda3/lib/python3.6/site-packages/gdxcc.py", line 17, in <module>
_gdxcc = swig_import_helper()
File "/Users/davidwogan/anaconda3/lib/python3.6/site-packages/gdxcc.py", line 16, in swig_import_helper
return importlib.import_module('_gdxcc')
File "/Users/davidwogan/anaconda3/lib/python3.6/importlib/__init__.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
ImportError: dlopen(/Users/davidwogan/anaconda3/lib/python3.6/site-packages/_gdxcc.so, 2): Symbol not found: _PyClass_Type
Referenced from: /Applications/GAMS25.0/sysdir/_gdxcc.so
Expected in: flat namespace
in /Applications/GAMS25.0/sysdir/_gdxcc.so
I am using Python 3.6 from Anaconda and GAMS 25.0 on OX 10.13.4. Is this a bug or is there something I am missing? Thanks in advance,
David Wogan