stencila/hub

"RuntimeError: Unhandled source type" with icomplete GitHub URL

sentry-io opened this issue · 0 comments

When a user attempted to create a new GitHub project source with url: github.com/<org>/<repo> this error was generated and there was no feedback. The complete URL https://github.com/<org>/<repo> does work.

Sentry Issue: HUB-15H

RuntimeError: Unhandled source type: 
  File "rest_framework/views.py", line 506, in dispatch
    response = handler(request, *args, **kwargs)
  File "projects/api/views/sources.py", line 238, in create
    return super().create(request, *args, **kwargs)
  File "manager/api/helpers.py", line 130, in create
    serializer = self.get_serializer(data=request.data)
  File "rest_framework/generics.py", line 108, in get_serializer
    serializer_class = self.get_serializer_class()
  File "projects/api/views/sources.py", line 127, in get_serializer_class
    raise RuntimeError(