happynear / py-leveldb-windows

A Visual Studio project to build leveldb python wrapper
94 stars 30 forks source link

AttributeError: module 'leveldb' has no attribute 'LevelDB' #8

Closed andyoknen closed 5 years ago

andyoknen commented 5 years ago

I download binary, place to /Lib/site-packages/leveldb.pyd Launch test app:

import leveldb
db = leveldb.LevelDB('./db')
...

and receive error:

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ImportError: DLL load failed: Не найден указанный модуль.

It is also impossible to compile from source https://github.com/happynear/py-leveldb-windows/issues/3

litvinovivan commented 5 years ago

The file is for Python 3.6. I had the same error with Python 3.7. Downgraded to Python 3.6 and it works fine now.

andyoknen commented 5 years ago

Its not actual now, but thanks you:) Information is useful in any case.