Python3 support for VirtualBox API
Posted: 31. May 2018, 16:47
I am trying to use the vboxapi module in python3.6. Importing works fine, however, running:
will crash with the following output:
Searching inside /Applications/VirtualBox.app/Contents/MacOS, I can find these two files: VBoxPython2_7.so and VBoxPython2_6.so.
I believe I should also find the corresponding .so files for python 3.6.
I tried linking python to python3.6 or creating an alias python=python3.6 hoping that installing VirtualBox this way would generate the files, but it didn't.
How can I obtain those files?
Code: Select all
vboxMgr = vboxapi.VirtualBoxManager(None, None)
Code: Select all
m=VBoxPython3_6m x=No module named 'VBoxPython3_6m'
m=VBoxPython3m x=No module named 'VBoxPython3m'
m=VBoxPython x=No module named 'VBoxPython'
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/local/lib/python3.6/site-packages/vboxapi/__init__.py", line 989, in __init__
self.platform = PlatformXPCOM(dPlatformParams)
File "/usr/local/lib/python3.6/site-packages/vboxapi/__init__.py", line 750, in __init__
import xpcom.vboxxpcom
File "/Applications/VirtualBox.app/Contents/MacOS/sdk/bindings/xpcom/python/xpcom/vboxxpcom.py", line 78, in <module>
raise Exception('Cannot find VBoxPython module (tried: %s)' % (', '.join(_asVBoxPythons),))
Exception: Cannot find VBoxPython module (tried: VBoxPython3_6m, VBoxPython3m, VBoxPython)
I believe I should also find the corresponding .so files for python 3.6.
I tried linking python to python3.6 or creating an alias python=python3.6 hoping that installing VirtualBox this way would generate the files, but it didn't.
How can I obtain those files?