Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bin/create-db: inbox.config No module named config [SOLVED] #429

Closed
Aegefel opened this issue Jan 21, 2017 · 5 comments
Closed

bin/create-db: inbox.config No module named config [SOLVED] #429

Aegefel opened this issue Jan 21, 2017 · 5 comments

Comments

@Aegefel
Copy link

Aegefel commented Jan 21, 2017

Hi,
I followed this tutorial to install Nylas Sync Engine on Ubuntu 16.10 but I can't get it works.
I tried to run it with python 3.5 but it doesn't works so I used python 2.7.
When I launch sudo -H setup.sh It automatically downgrade pip to the version 8.1.2
Ensuring setuptools and pip versions...
Collecting pip==8.1.2
Using cached pip-8.1.2-py2.py3-none-any.whl
Requirement already satisfied: setuptools>=5.3 in /usr/lib/python2.7/dist-packages
Installing collected packages: pip
Found existing installation: pip 9.0.1
Uninstalling pip-9.0.1:
Successfully uninstalled pip-9.0.1
Successfully installed pip-8.1.2

Then it says:
Copying default mysql configuration to /etc/mysql/conf.d
2017-01-21T18:54:39.330729Z mysqld_safe Logging to syslog.
2017-01-21T18:54:39.332573Z mysqld_safe Logging to '/var/log/mysql/error.log'.
2017-01-21T18:54:39.334704Z mysqld_safe Logging to '/var/log/mysql/error.log'.
2017-01-21T18:54:39.336648Z mysqld_safe Directory '/var/run/mysqld' for UNIX socket file don't exists.
Traceback (most recent call last):
File "bin/create-db", line 9, in <module>
from inbox.config import config
ImportError: No module named config
I don't know how to fix this problem. Any ideas ?

@kun-zhou
Copy link

#427 The issue is resolved in a previous post.

@Aegefel
Copy link
Author

Aegefel commented Jan 22, 2017

I don't have vagrant installed so it doesn't work for me. Do I have to install vagrant ? Why is it necessary to run the sync engine ?

@kun-zhou
Copy link

kun-zhou commented Jan 22, 2017

You don't need vagrant if that is your preference. I have the sync engine up and running on a remote amazon virtual machine without using vagrant, just run the setup.sh. You do need to install a few failed dependencies using easy_install along the way. I also remember needing to fix a few permission issues for the folders. Make sure you are in the the immediate mother directory of bin.

Also, you might want to reinstall MySQL if you've installed it before because the configurations can differ.

UPDATE: Notice that the previous post added /vagrant to the front of its sys.path, if you are not using vagrant, you might have a different path. For me, it was /home/kunzhou/sync-engine.

@Aegefel
Copy link
Author

Aegefel commented Jan 25, 2017

Thank you. I added the lines sys.path = ["/home/aegefel/Desktop/nylas_tmp/sync-engine"] + [p for p in sys.path if p != "/home/aegefel/Desktop/nylas_tmp/sync-engine"] in inbox-auth, inbox-api, inbox-start and create-db and it worked. Problem solved !

@Aegefel Aegefel changed the title bin/create-db: inbox.config No module named config bin/create-db: inbox.config No module named config [SOLVED] Jan 25, 2017
@grinich grinich closed this as completed Jan 31, 2017
@slotlocker2
Copy link

I think a more elegant solution would be to define the PYTHONPATH before running setup.sh

export PYTHONPATH=".":$PYTHONPATH
bash setup.sh

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants