Hello all,
I am trying to install insight in ubuntu 20.04 but ansible failing at TASK [edx_django_service : migrate database]
Followed docs for installation: https://openedx.atlassian.net/wiki/spaces/OpenOPS/pages/43385371/edX+Analytics+Installation
Error:
"fatal":[
"localhost"
]:"FAILED! =>"{
"changed":true,
"cmd":[
"make",
"migrate"
],
"delta":"0:00:00.896337",
"end":"2022-01-10 15:18:46.570530",
"msg":"non-zero return code",
"rc":2,
"start":"2022-01-10 15:18:45.674193",
"stderr":"Traceback (most recent call last):\n File \"./manage.py\", line 10, in <module>\n execute_from_command_line(sys.argv)\n File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/core/management/__init__.py\", line 419, in execute_from_command_line\n utility.execute()\n File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/core/management/__init__.py\", line 413, in execute\n self.fetch_command(subcommand).run_from_argv(self.argv)\n File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/core/management/base.py\", line 354, in run_from_argv\n self.execute(*args, **cmd_options)\n File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/core/management/base.py\", line 398, in execute\n output = self.handle(*args, **options)\n File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/core/management/base.py\", line 89, in wrapped\n res = handle_func(*args, **kwargs)\n File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/core/management/commands/migrate.py\", line 75, in handle\n self.check(databases=[database])\n File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/core/management/base.py\", line 419, in check\n all_issues = checks.run_checks(\n File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/core/checks/registry.py\", line 76, in run_checks\n new_errors = check(app_configs=app_configs, databases=databases)\n File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/core/checks/urls.py\", line 13, in check_url_config\n return check_resolver(resolver)\n File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/core/checks/urls.py\", line 23, in check_resolver\n return check_method()\n File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/urls/resolvers.py\", line 416, in check\n for pattern in self.url_patterns:\n File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/utils/functional.py\", line 48, in __get__\n res = instance.__dict__[self.name] = self.func(instance)\n File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/urls/resolvers.py\", line 602, in url_patterns\n patterns = getattr(self.urlconf_module, \"urlpatterns\", self.urlconf_module)\n File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/utils/functional.py\", line 48, in __get__\n res = instance.__dict__[self.name] = self.func(instance)\n File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/urls/resolvers.py\", line 595, in urlconf_module\n return import_module(self.urlconf_name)\n File \"/usr/lib/python3.8/importlib/__init__.py\", line 127, in import_module\n return _bootstrap._gcd_import(name[level:], package, level)\n File \"<frozen importlib._bootstrap>\", line 1014, in _gcd_import\n File \"<frozen importlib._bootstrap>\", line 991, in _find_and_load\n File \"<frozen importlib._bootstrap>\", line 975, in _find_and_load_unlocked\n File \"<frozen importlib._bootstrap>\", line 671, in _load_unlocked\n File \"<frozen importlib._bootstrap_external>\", line 848, in exec_module\n File \"<frozen importlib._bootstrap>\", line 219, in _call_with_frames_removed\n File \"/edx/app/analytics_api/analytics_api/analyticsdataserver/urls.py\", line 16, in <module>\n url(r'^api/', include('analytics_data_api.urls')),\n File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/urls/conf.py\", line 34, in include\n urlconf_module = import_module(urlconf_module)\n File \"/usr/lib/python3.8/importlib/__init__.py\", line 127, in import_module\n return _bootstrap._gcd_import(name[level:], package, level)\n File \"<frozen importlib._bootstrap>\", line 1014, in _gcd_import\n File \"<frozen importlib._bootstrap>\", line 991, in _find_and_load\n File \"<frozen importlib._bootstrap>\", line 975, in _find_and_load_unlocked\n File \"<frozen importlib._bootstrap>\", line 671, in _load_unlocked\n File \"<frozen importlib._bootstrap_external>\", line 848, in exec_module\n File \"<frozen importlib._bootstrap>\", line 219, in _call_with_frames_removed\n File \"/edx/app/analytics_api/analytics_api/analytics_data_api/urls.py\", line 7, in <module>\n url(r'^v0/', include('analytics_data_api.v0.urls')),\n File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/urls/conf.py\", line 34, in include\n urlconf_module = import_module(urlconf_module)\n File \"/usr/lib/python3.8/importlib/__init__.py\", line 127, in import_module\n return _bootstrap._gcd_import(name[level:], package, level)\n File \"<frozen importlib._bootstrap>\", line 1014, in _gcd_import\n File \"<frozen importlib._bootstrap>\", line 991, in _find_and_load\n File \"<frozen importlib._bootstrap>\", line 975, in _find_and_load_unlocked\n File \"<frozen importlib._bootstrap>\", line 671, in _load_unlocked\n File \"<frozen importlib._bootstrap_external>\", line 848, in exec_module\n File \"<frozen importlib._bootstrap>\", line 219, in _call_with_frames_removed\n File \"/edx/app/analytics_api/analytics_api/analytics_data_api/v0/urls/__init__.py\", line 13, in <module>\n url('^', include('analytics_data_api.v0.urls.learners')),\n File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/urls/conf.py\", line 34, in include\n urlconf_module = import_module(urlconf_module)\n File \"/usr/lib/python3.8/importlib/__init__.py\", line 127, in import_module\n return _bootstrap._gcd_import(name[level:], package, level)\n File \"<frozen importlib._bootstrap>\", line 1014, in _gcd_import\n File \"<frozen importlib._bootstrap>\", line 991, in _find_and_load\n File \"<frozen importlib._bootstrap>\", line 975, in _find_and_load_unlocked\n File \"<frozen importlib._bootstrap>\", line 671, in _load_unlocked\n File \"<frozen importlib._bootstrap_external>\", line 848, in exec_module\n File \"<frozen importlib._bootstrap>\", line 219, in _call_with_frames_removed\n File \"/edx/app/analytics_api/analytics_api/analytics_data_api/v0/urls/learners.py\", line 5, in <module>\n from analytics_data_api.v0.views import learners as views\n File \"/edx/app/analytics_api/analytics_api/analytics_data_api/v0/views/learners.py\", line 13, in <module>\n from analytics_data_api.v0.documents import RosterEntry, RosterUpdate\n File \"/edx/app/analytics_api/analytics_api/analytics_data_api/v0/documents.py\", line 29, in <module>\n class RosterEntry(Document):\n File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/elasticsearch_dsl/document.py\", line 58, in __new__\n index = cls.construct_index(index_opts, bases)\n File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/elasticsearch_dsl/document.py\", line 76, in construct_index\n i.aliases(**getattr(opts, \"aliases\", {}))\nTypeError: aliases() keywords must be strings\nmake: *** [Makefile:111: migrate] Error 1",
"stderr_lines":[
"Traceback (most recent call last):",
" File \"./manage.py\", line 10, in <module>",
" execute_from_command_line(sys.argv)",
" File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/core/management/__init__.py\", line 419, in execute_from_command_line",
" utility.execute()",
" File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/core/management/__init__.py\", line 413, in execute",
" self.fetch_command(subcommand).run_from_argv(self.argv)",
" File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/core/management/base.py\", line 354, in run_from_argv",
" self.execute(*args, **cmd_options)",
" File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/core/management/base.py\", line 398, in execute",
" output = self.handle(*args, **options)",
" File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/core/management/base.py\", line 89, in wrapped",
" res = handle_func(*args, **kwargs)",
" File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/core/management/commands/migrate.py\", line 75, in handle",
" self.check(databases=[database])",
" File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/core/management/base.py\", line 419, in check",
" all_issues = checks.run_checks(",
" File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/core/checks/registry.py\", line 76, in run_checks",
" new_errors = check(app_configs=app_configs, databases=databases)",
" File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/core/checks/urls.py\", line 13, in check_url_config",
" return check_resolver(resolver)",
" File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/core/checks/urls.py\", line 23, in check_resolver",
" return check_method()",
" File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/urls/resolvers.py\", line 416, in check",
" for pattern in self.url_patterns:",
" File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/utils/functional.py\", line 48, in __get__",
" res = instance.__dict__[self.name] = self.func(instance)",
" File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/urls/resolvers.py\", line 602, in url_patterns",
" patterns = getattr(self.urlconf_module, \"urlpatterns\", self.urlconf_module)",
" File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/utils/functional.py\", line 48, in __get__",
" res = instance.__dict__[self.name] = self.func(instance)",
" File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/urls/resolvers.py\", line 595, in urlconf_module",
" return import_module(self.urlconf_name)",
" File \"/usr/lib/python3.8/importlib/__init__.py\", line 127, in import_module",
" return _bootstrap._gcd_import(name[level:], package, level)",
" File \"<frozen importlib._bootstrap>\", line 1014, in _gcd_import",
" File \"<frozen importlib._bootstrap>\", line 991, in _find_and_load",
" File \"<frozen importlib._bootstrap>\", line 975, in _find_and_load_unlocked",
" File \"<frozen importlib._bootstrap>\", line 671, in _load_unlocked",
" File \"<frozen importlib._bootstrap_external>\", line 848, in exec_module",
" File \"<frozen importlib._bootstrap>\", line 219, in _call_with_frames_removed",
" File \"/edx/app/analytics_api/analytics_api/analyticsdataserver/urls.py\", line 16, in <module>",
" url(r'^api/', include('analytics_data_api.urls')),",
" File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/urls/conf.py\", line 34, in include",
" urlconf_module = import_module(urlconf_module)",
" File \"/usr/lib/python3.8/importlib/__init__.py\", line 127, in import_module",
" return _bootstrap._gcd_import(name[level:], package, level)",
" File \"<frozen importlib._bootstrap>\", line 1014, in _gcd_import",
" File \"<frozen importlib._bootstrap>\", line 991, in _find_and_load",
" File \"<frozen importlib._bootstrap>\", line 975, in _find_and_load_unlocked",
" File \"<frozen importlib._bootstrap>\", line 671, in _load_unlocked",
" File \"<frozen importlib._bootstrap_external>\", line 848, in exec_module",
" File \"<frozen importlib._bootstrap>\", line 219, in _call_with_frames_removed",
" File \"/edx/app/analytics_api/analytics_api/analytics_data_api/urls.py\", line 7, in <module>",
" url(r'^v0/', include('analytics_data_api.v0.urls')),",
" File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/urls/conf.py\", line 34, in include",
" urlconf_module = import_module(urlconf_module)",
" File \"/usr/lib/python3.8/importlib/__init__.py\", line 127, in import_module",
" return _bootstrap._gcd_import(name[level:], package, level)",
" File \"<frozen importlib._bootstrap>\", line 1014, in _gcd_import",
" File \"<frozen importlib._bootstrap>\", line 991, in _find_and_load",
" File \"<frozen importlib._bootstrap>\", line 975, in _find_and_load_unlocked",
" File \"<frozen importlib._bootstrap>\", line 671, in _load_unlocked",
" File \"<frozen importlib._bootstrap_external>\", line 848, in exec_module",
" File \"<frozen importlib._bootstrap>\", line 219, in _call_with_frames_removed",
" File \"/edx/app/analytics_api/analytics_api/analytics_data_api/v0/urls/__init__.py\", line 13, in <module>",
" url('^', include('analytics_data_api.v0.urls.learners')),",
" File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/django/urls/conf.py\", line 34, in include",
" urlconf_module = import_module(urlconf_module)",
" File \"/usr/lib/python3.8/importlib/__init__.py\", line 127, in import_module",
" return _bootstrap._gcd_import(name[level:], package, level)",
" File \"<frozen importlib._bootstrap>\", line 1014, in _gcd_import",
" File \"<frozen importlib._bootstrap>\", line 991, in _find_and_load",
" File \"<frozen importlib._bootstrap>\", line 975, in _find_and_load_unlocked",
" File \"<frozen importlib._bootstrap>\", line 671, in _load_unlocked",
" File \"<frozen importlib._bootstrap_external>\", line 848, in exec_module",
" File \"<frozen importlib._bootstrap>\", line 219, in _call_with_frames_removed",
" File \"/edx/app/analytics_api/analytics_api/analytics_data_api/v0/urls/learners.py\", line 5, in <module>",
" from analytics_data_api.v0.views import learners as views",
" File \"/edx/app/analytics_api/analytics_api/analytics_data_api/v0/views/learners.py\", line 13, in <module>",
" from analytics_data_api.v0.documents import RosterEntry, RosterUpdate",
" File \"/edx/app/analytics_api/analytics_api/analytics_data_api/v0/documents.py\", line 29, in <module>",
" class RosterEntry(Document):",
" File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/elasticsearch_dsl/document.py\", line 58, in __new__",
" index = cls.construct_index(index_opts, bases)",
" File \"/edx/app/analytics_api/venvs/analytics_api/lib/python3.8/site-packages/elasticsearch_dsl/document.py\", line 76, in construct_index",
" i.aliases(**getattr(opts, \"aliases\", {}))",
"TypeError: aliases() keywords must be strings",
"make: *** [Makefile:111: migrate] Error 1"
],
"stdout":"./manage.py migrate --noinput --run-syncdb --database=default",
"stdout_lines":[
"./manage.py migrate --noinput --run-syncdb --database=default"
]
}
Anyone could help me?