python - Bitnami Django Stack and module "requests": cannot import name 'certs' -
very specific stuff. i'm running bitnami django stack cloud vm on amazon. on 2 different "regular" machines, install requests
running sudo pip install requests
, seems bitname uses it's own specific structure, , going wrong when installing requests
way. can related issue #2028, fixed long time ago.
i have following traceback:
environment: request method: request url: http://54.94.226.137/ django version: 1.7.7 python version: 2.7.6 installed applications: ('django.contrib.admin', 'django.contrib.auth', 'django.contrib.contenttypes', 'django.contrib.sessions', 'django.contrib.messages', 'django.contrib.staticfiles', 'django.contrib.sites', 'vz_base', 'vz_api', 'vz_admin', 'vz_user') installed middleware: ('django.contrib.sessions.middleware.sessionmiddleware', 'django.middleware.common.commonmiddleware', 'django.middleware.csrf.csrfviewmiddleware', 'django.contrib.auth.middleware.authenticationmiddleware', 'django.contrib.auth.middleware.sessionauthenticationmiddleware', 'django.contrib.messages.middleware.messagemiddleware', 'django.middleware.clickjacking.xframeoptionsmiddleware') traceback: file "/opt/bitnami/python/lib/python2.7/site-packages/django/core/handlers/base.py" in get_response 98. resolver_match = resolver.resolve(request.path_info) file "/opt/bitnami/python/lib/python2.7/site-packages/django/core/urlresolvers.py" in resolve 343. pattern in self.url_patterns: file "/opt/bitnami/python/lib/python2.7/site-packages/django/core/urlresolvers.py" in url_patterns 372. patterns = getattr(self.urlconf_module, "urlpatterns", self.urlconf_module) file "/opt/bitnami/python/lib/python2.7/site-packages/django/core/urlresolvers.py" in urlconf_module 366. self._urlconf_module = import_module(self.urlconf_name) file "/opt/bitnami/python/lib/python2.7/importlib/__init__.py" in import_module 37. __import__(name) file "/opt/bitnami/apps/django/django_projects/projetovigzul/projetovigzul/urls.py" in <module> 5. vz_api import urls api_urls file "/opt/bitnami/apps/django/django_projects/projetovigzul/vz_api/urls.py" in <module> 8. vz_api import views file "/opt/bitnami/apps/django/django_projects/projetovigzul/vz_api/views.py" in <module> 14. vz_api.dguard import dguardmanager, dguardintegrationexception file "/opt/bitnami/apps/django/django_projects/projetovigzul/vz_api/dguard.py" in <module> 5. import requests, json file "/opt/bitnami/python/lib/python2.7/site-packages/requests/__init__.py" in <module> 58. . import utils file "/opt/bitnami/python/lib/python2.7/site-packages/requests/utils.py" in <module> 25. . import certs exception type: importerror @ / exception value: cannot import name certs
website live @ http://54.94.226.137/, if interested.
sudo pip install --upgrade requests
solved me
Comments
Post a Comment