Open moshthepitt opened 5 years ago
Traceback: File "/home/ubuntu/.local/share/virtualenvs/kaznet-web-RsG8VRta/lib/python3.6/site-packages/django/core/handlers/exception.py" in inner 35. response = get_response(request) File "/home/ubuntu/.local/share/virtualenvs/kaznet-web-RsG8VRta/lib/python3.6/site-packages/django/core/handlers/base.py" in _get_response 128. response = self.process_exception_by_middleware(e, request) File "/home/ubuntu/.local/share/virtualenvs/kaznet-web-RsG8VRta/lib/python3.6/site-packages/django/core/handlers/base.py" in _get_response 126. response = wrapped_callback(request, *callback_args, **callback_kwargs) File "/home/ubuntu/.local/share/virtualenvs/kaznet-web-RsG8VRta/lib/python3.6/site-packages/django/views/decorators/csrf.py" in wrapped_view 54. return view_func(*args, **kwargs) File "/home/ubuntu/.local/share/virtualenvs/kaznet-web-RsG8VRta/lib/python3.6/site-packages/rest_framework/viewsets.py" in view 103. return self.dispatch(request, *args, **kwargs) File "/home/ubuntu/.local/share/virtualenvs/kaznet-web-RsG8VRta/lib/python3.6/site-packages/rest_framework/views.py" in dispatch 483. response = self.handle_exception(exc) File "/home/ubuntu/.local/share/virtualenvs/kaznet-web-RsG8VRta/lib/python3.6/site-packages/rest_framework/views.py" in handle_exception 443. self.raise_uncaught_exception(exc) File "/home/ubuntu/.local/share/virtualenvs/kaznet-web-RsG8VRta/lib/python3.6/site-packages/rest_framework/views.py" in dispatch 480. response = handler(request, *args, **kwargs) File "/home/ubuntu/.local/share/virtualenvs/kaznet-web-RsG8VRta/lib/python3.6/site-packages/rest_framework/mixins.py" in create 20. serializer.is_valid(raise_exception=True) File "/home/ubuntu/.local/share/virtualenvs/kaznet-web-RsG8VRta/lib/python3.6/site-packages/rest_framework/serializers.py" in is_valid 236. self._validated_data = self.run_validation(self.initial_data) File "/home/ubuntu/.local/share/virtualenvs/kaznet-web-RsG8VRta/lib/python3.6/site-packages/rest_framework/serializers.py" in run_validation 434. value = self.to_internal_value(data) File "/home/ubuntu/.local/share/virtualenvs/kaznet-web-RsG8VRta/lib/python3.6/site-packages/rest_framework/serializers.py" in to_internal_value 488. validated_value = field.run_validation(primitive_value) File "/home/ubuntu/.local/share/virtualenvs/kaznet-web-RsG8VRta/lib/python3.6/site-packages/rest_framework/fields.py" in run_validation 523. value = self.to_internal_value(data) File "/home/ubuntu/.local/share/virtualenvs/kaznet-web-RsG8VRta/src/ona-tasking/tasking/serializers/location.py" in to_internal_value 81. multipolygon = MultiPolygon(polygons) File "/home/ubuntu/.local/share/virtualenvs/kaznet-web-RsG8VRta/lib/python3.6/site-packages/django/contrib/gis/geos/collections.py" in __init__ 34. self._check_allowed(init_geoms) File "/home/ubuntu/.local/share/virtualenvs/kaznet-web-RsG8VRta/lib/python3.6/site-packages/django/contrib/gis/geos/mutable_list.py" in _check_allowed 250. raise TypeError('Invalid type encountered in the arguments.') Exception Type: TypeError at /api/v1/locations/ Exception Value: Invalid type encountered in the arguments.
An example of a shapefile that fails:
K22.zip
Related https://github.com/onaio/tasking/issues/142