I get an exception No connection adapters were found for "['https://uk-hairloom.atlassian.net/']/rest/agile/1.0/board?maxResults=50" when hitting my test_connection method.
When I trace this back to the view and print the POST request object in a standard django view, the values are wrapped in an array and I don't understand why. Weird thing is if I do a GET for all objects using postman, they are not wrapped in array and appear as strings. FYI model fields are TextField NOT list.
class JiraDataViewSet(BaseModelViewSet):
queryset = JiraData.objects.all().order_by("-id")
serializer_class = JiraDataSerializer
permission_classes = [
IsAdmin,
]
lookup_field = "uuid"
@action(detail=False, methods=["post"])
def test_connection(self, request, *args, **kwargs):
result = False
if request.data:
try:
details = JiraData(**request.data)
if details:
if test_get_all_boards(details):
result = True
except Exception as e:
print('printing exception')
print(e)
pass
Exception looks like:
No connection adapters were found for "['https://uk-
hairloom.atlassian.net/']/rest/agile/1.0/board?maxResults=50"
Any advice much appreciated.