Closed changeling closed 5 years ago
Clicking on All persons returns error in console, fails.
All persons
A request sent to http://localhost:3000/persona/list/ in the browser results in the following:
http://localhost:3000/persona/list/
Log:
2019-02-22 19:38:58,407 to_json 61678 123145347530752 geneaprove.views.persona.PersonaList.get(<JSONViewParams: {'theme': ['[object Object]']}>)
Console:
[22/Feb/2019 19:39:12] "GET /data/persona/list?theme=[object%20Object] HTTP/1.1" 500 148036
Full stacktrace:
[22/Feb/2019 19:49:30] "GET /data/csrf HTTP/1.1" 200 127 2019-02-22 19:49:32,256 get geneaprove.views.persona.PersonaList.get(<JSONViewParams: {'theme': ['[object Object]']}>) Internal Server Error: /data/persona/list Traceback (most recent call last): File "/Users/clarson/Desktop/geneapro-test-django-branch/python_env/lib/python3.6/site-packages/django/core/handlers/exception.py", line 42, in inner response = get_response(request) File "/Users/clarson/Desktop/geneapro-test-django-branch/python_env/lib/python3.6/site-packages/django/core/handlers/base.py", line 187, in _get_response response = self.process_exception_by_middleware(e, request) File "/Users/clarson/Desktop/geneapro-test-django-branch/python_env/lib/python3.6/site-packages/django/core/handlers/base.py", line 185, in _get_response response = wrapped_callback(request, *callback_args, **callback_kwargs) File "/Users/clarson/Desktop/geneapro-test-django-branch/python_env/lib/python3.6/site-packages/django/views/generic/base.py", line 68, in view return self.dispatch(request, *args, **kwargs) File "/Users/clarson/Desktop/geneapro-test-django-branch/python_env/lib/python3.6/site-packages/django/views/generic/base.py", line 88, in dispatch return handler(request, *args, **kwargs) File "/Users/clarson/Desktop/geneapro-test-django-branch/backend/geneaprove/views/to_json.py", line 173, in get return self.__internal(self.get_json, params, *args, **kwargs) File "/Users/clarson/Desktop/geneapro-test-django-branch/backend/geneaprove/views/to_json.py", line 158, in __internal resp = method(params, *args, **kwargs) or {"success": True} File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/contextlib.py", line 52, in inner return func(*args, **kwds) File "/Users/clarson/Desktop/geneapro-test-django-branch/backend/geneaprove/views/persona.py", line 254, in get_json styles = Styles(theme_id, graph=global_graph, decujus=decujus) File "/Users/clarson/Desktop/geneapro-test-django-branch/backend/geneaprove/views/styles.py", line 68, in __init__ .get(id=theme_id) File "/Users/clarson/Desktop/geneapro-test-django-branch/python_env/lib/python3.6/site-packages/django/db/models/query.py", line 376, in get clone = self.filter(*args, **kwargs) File "/Users/clarson/Desktop/geneapro-test-django-branch/python_env/lib/python3.6/site-packages/django/db/models/query.py", line 796, in filter return self._filter_or_exclude(False, *args, **kwargs) File "/Users/clarson/Desktop/geneapro-test-django-branch/python_env/lib/python3.6/site-packages/django/db/models/query.py", line 814, in _filter_or_exclude clone.query.add_q(Q(*args, **kwargs)) File "/Users/clarson/Desktop/geneapro-test-django-branch/python_env/lib/python3.6/site-packages/django/db/models/sql/query.py", line 1227, in add_q clause, _ = self._add_q(q_object, self.used_aliases) File "/Users/clarson/Desktop/geneapro-test-django-branch/python_env/lib/python3.6/site-packages/django/db/models/sql/query.py", line 1253, in _add_q allow_joins=allow_joins, split_subq=split_subq, File "/Users/clarson/Desktop/geneapro-test-django-branch/python_env/lib/python3.6/site-packages/django/db/models/sql/query.py", line 1187, in build_filter condition = self.build_lookup(lookups, col, value) File "/Users/clarson/Desktop/geneapro-test-django-branch/python_env/lib/python3.6/site-packages/django/db/models/sql/query.py", line 1083, in build_lookup return final_lookup(lhs, rhs) File "/Users/clarson/Desktop/geneapro-test-django-branch/python_env/lib/python3.6/site-packages/django/db/models/lookups.py", line 19, in __init__ self.rhs = self.get_prep_lookup() File "/Users/clarson/Desktop/geneapro-test-django-branch/python_env/lib/python3.6/site-packages/django/db/models/lookups.py", line 59, in get_prep_lookup return self.lhs.output_field.get_prep_value(self.rhs) File "/Users/clarson/Desktop/geneapro-test-django-branch/python_env/lib/python3.6/site-packages/django/db/models/fields/__init__.py", line 946, in get_prep_value return int(value) ValueError: invalid literal for int() with base 10: '[object Object]' 2019-02-22 19:49:32,455 get geneaprove.views.themelist.ThemeList.get(<JSONViewParams: {}>) 2019-02-22 19:49:32,483 __internal convert to json 2019-02-22 19:49:32,488 __internal send response Total time: 0.040783s / queries time (1 queries): 0.017000s [22/Feb/2019 19:49:32] "GET /data/themelist HTTP/1.1" 200 18 Total time: 18.451111s / queries time (5 queries): 0.003000s [22/Feb/2019 19:49:51] "GET /data/persona/list?theme=[object%20Object] HTTP/1.1" 500 148036
Clicking on
All persons
returns error in console, fails.A request sent to
http://localhost:3000/persona/list/
in the browser results in the following:Log:
Console:
Full stacktrace: