Пытаюсь поднять локальную версию бнвачика, дабы немного его допилить.
Смело преодолел мелкие несоответствия инструкции по установке и кода (пулл-реквест, а может, просто жалоб и нытья пост, будет позже).
Но:
$ test -d .venv && echo 'yes'
yes
$ make run
if test -d .venv; then\
bash -c "source .venv/bin/activate && twistd -ny bnw/scripts/instance.py";\
else\
twistd -ny bnw/scripts/instance.py;\
fi
Unhandled Error
Traceback (most recent call last):
File "/usr/lib/python2.7/dist-packages/twisted/application/app.py", line 642, in run
runApp(config)
File "/usr/lib/python2.7/dist-packages/twisted/scripts/twistd.py", line 23, in runApp
_SomeApplicationRunner(config).run()
File "/usr/lib/python2.7/dist-packages/twisted/application/app.py", line 376, in run
self.application = self.createOrGetApplication()
File "/usr/lib/python2.7/dist-packages/twisted/application/app.py", line 441, in createOrGetApplication
application = getApplication(self.config, passphrase)
--- <exception caught here> ---
File "/usr/lib/python2.7/dist-packages/twisted/application/app.py", line 452, in getApplication
application = service.loadApplication(filename, style, passphrase)
File "/usr/lib/python2.7/dist-packages/twisted/application/service.py", line 405, in loadApplication
application = sob.loadValueFromFile(filename, 'application', passphrase)
File "/usr/lib/python2.7/dist-packages/twisted/persisted/sob.py", line 210, in loadValueFromFile
exec fileObj in d, d
File "bnw/scripts/instance.py", line 26, in <module>
from bnw.core.bnw_mongo import open_db
File "/home/minoru/docs/git/bnw/bnw/core/bnw_mongo.py", line 7, in <module>
import motor
exceptions.ImportError: No module named motor
Failed to load application: No module named motor
Makefile:59: recipe for target 'run' failed
make: *** [run] Error 1
При этом:
$ bash -c 'source .venv/bin/activate && python'
Python 2.7.8 (default, Jul 26 2014, 15:25:14)
[GCC 4.9.1] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import motor
>>> motor.MotorClient()
MotorClient(MongoClient([]))
>>>
Как это починить?