I installed OpenBabel for Mac using:
brew install open-babel
I tried to work with pyenv version 3.9.0 and got the following error :
ImportError:
dlopen(/Users/mac_hd/.pyenv/versions/testGUIenv22/lib/python3.9/site-packages/openbabel/_openbabel.cpython-39-darwin.so, 2): Symbol not found: __ZN9OpenBabel8OBPlugin7DisplayERNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEEPKcSA_
Referenced from: /Users/mac_hd/.pyenv/versions/testGUIenv22/lib/python3.9/site-packages/openbabel/_openbabel.cpython-39-darwin.so
Expected in: flat namespace
in /Users/mac_hd/.pyenv/versions/testGUIenv22/lib/python3.9/site-packages/openbabel/_openbabel.cpython-39-darwin.so
How can I fix this error?
when I run brew config
I get:
HOMEBREW_VERSION: 2.7.1
ORIGIN: https://github.com/Homebrew/brew
HEAD: fdb71a5cb3029da2ef74d7e09c40575bbfb4ec72
Last commit: 6 days ago
Core tap ORIGIN: https://github.com/Homebrew/homebrew-core
Core tap HEAD: adc0a9c1b10dc727dfe33403e2277609147e0cff
Core tap last commit: 7 hours ago
Core tap branch: master
HOMEBREW_PREFIX: /usr/local
HOMEBREW_CASK_OPTS: []
HOMEBREW_MAKE_JOBS: 4
Homebrew Ruby: 2.6.3 => /usr/local/Homebrew/Library/Homebrew/vendor/portable-ruby/2.6.3_2/bin/ruby
CPU: quad-core 64-bit ivybridge
Clang: 12.0 build 1200
Git: 2.23.0 => /usr/local/bin/git
Curl: 7.64.1 => /usr/bin/curl
Java: 15, 13.0.2
macOS: 10.15.7-x86_64
CLT: 12.0.31.1
Xcode: N/A
XQuartz: 2.7.11 => /opt/X11
@user14499583 From what I understand from here you might want to check which python version is used by open-babel. It seems to be a Python version problem at first look.