hotosm / osm-tasking-manager2

Designed and built for Humanitarian OpenStreetMap Team collaborative emergency/disaster mapping, the OSM Tasking Manager 2.0 divides an area into individual squares that can be rapidly mapped by thousands of volunteers.
http://tasks.hotosm.org
Other
425 stars 156 forks source link

./env/bin/initialize_osmtm_db returns error #998

Closed fazlerabbi37 closed 6 years ago

fazlerabbi37 commented 6 years ago

OS: Ubuntu 16.04 I was following Debian installation form Wiki. Upon giving ./env/bin/initialize_osmtm_db I got the following errors: Traceback (most recent call last): File "./env/bin/initialize_osmtm_db", line 11, in load_entry_point('osmtm', 'console_scripts', 'initialize_osmtm_db')() File "/home/user/osm-tasking-manager2/env/lib/python3.5/site-packages/pkg_resources/init.py", line 570, in load_entry_point return get_distribution(dist).load_entry_point(group, name) File "/home/user/osm-tasking-manager2/env/lib/python3.5/site-packages/pkg_resources/init.py", line 2755, in load_entry_point return ep.load() File "/home/user/osm-tasking-manager2/env/lib/python3.5/site-packages/pkg_resources/init.py", line 2409, in load return self.resolve() File "/home/user/osm-tasking-manager2/env/lib/python3.5/site-packages/pkg_resources/init.py", line 2415, in resolve module = import(self.module_name, fromlist=['name'], level=0) File "/home/user/osm-tasking-manager2/osmtm/init.py", line 11, in from .models import ( File "/home/user/osm-tasking-manager2/osmtm/models.py", line 56, in from .utils import ( File "/home/user/osm-tasking-manager2/osmtm/utils.py", line 2, in import ConfigParser ImportError: No module named 'ConfigParser'

Can anybody please help me resolve this?

pgiraud commented 6 years ago

Just in case, what version of python are you using?

fazlerabbi37 commented 6 years ago

@pgiraud Python version 3.5.2

pgiraud commented 6 years ago

Could you try using python 2.x? I don't think TM2 can work with python 3.x unfortunately. You should be able to choose which version to use when initializing the virtual env.

fazlerabbi37 commented 6 years ago

thanks! solved it with the following command: virtualenv --python=/usr/bin/python2.7 --no-site-packages env