Skip to content

HTTPError at /complete/fiware/ #24

@francucchi

Description

@francucchi

Hello,
I'm running dockerized images of wirecloud+nginx and keyrock (with OAuth2) and I'm having some issues probably related to gunicorn running in the wirecloud image.
Here's below the stack trace:

Environment:

Request Method: GET
Request URL: http://192.168.5.205/complete/fiware/?code=787979c8344a72a03386f1a4863e8c1a82f2851f&state=AIx9Oo103l7biQT8XOzCqNg0A0XkUrH0

Django Version: 1.11.18
Python Version: 3.6.8
Installed Applications:
('django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.messages',
'django.contrib.staticfiles',
'django.contrib.admin',
'wirecloud.commons',
'compressor',
'wirecloud.catalogue',
'wirecloud.platform',
'wirecloud.fiware',
'social_django',
'haystack',
'wirecloud_pubsub')
Installed Middleware:
('wirecloud.commons.middleware.URLMiddleware',)

Traceback:

File "/usr/local/lib/python3.6/site-packages/django/core/handlers/exception.py" in inner
41. response = get_response(request)

File "/usr/local/lib/python3.6/site-packages/django/core/handlers/base.py" in _legacy_get_response
249. response = self._get_response(request)

File "/usr/local/lib/python3.6/site-packages/django/core/handlers/base.py" in _get_response
187. response = self.process_exception_by_middleware(e, request)

File "/usr/local/lib/python3.6/site-packages/django/core/handlers/base.py" in _get_response
185. response = wrapped_callback(request, *callback_args, **callback_kwargs)

File "/usr/local/lib/python3.6/site-packages/django/views/decorators/cache.py" in _wrapped_view_func
57. response = view_func(request, *args, **kwargs)

File "/usr/local/lib/python3.6/site-packages/django/views/decorators/csrf.py" in wrapped_view
58. return view_func(*args, **kwargs)

File "/usr/local/lib/python3.6/site-packages/social_django/utils.py" in wrapper
49. return func(request, backend, *args, **kwargs)

File "/usr/local/lib/python3.6/site-packages/social_django/views.py" in complete
33. *args, **kwargs)

File "/usr/local/lib/python3.6/site-packages/social_core/actions.py" in do_complete
43. user = backend.complete(user=user, *args, **kwargs)

File "/usr/local/lib/python3.6/site-packages/social_core/backends/base.py" in complete
40. return self.auth_complete(*args, **kwargs)

File "/usr/local/lib/python3.6/site-packages/social_core/utils.py" in wrapper
259. return func(*args, **kwargs)

File "/usr/local/lib/python3.6/site-packages/social_core/backends/oauth.py" in auth_complete
401. method=self.ACCESS_TOKEN_METHOD

File "/usr/local/lib/python3.6/site-packages/social_core/backends/oauth.py" in request_access_token
373. return self.get_json(*args, **kwargs)

File "/usr/local/lib/python3.6/site-packages/social_core/backends/base.py" in get_json
238. return self.request(url, *args, **kwargs).json()

File "/usr/local/lib/python3.6/site-packages/social_core/backends/base.py" in request
234. response.raise_for_status()

File "/usr/local/lib/python3.6/site-packages/requests/models.py" in raise_for_status
940. raise HTTPError(http_error_msg, response=self)

Exception Type: HTTPError at /complete/fiware/
Exception Value: 500 Server Error: Internal Server Error for url: http://192.168.5.205:3005/oauth2/token

I have all the cookies:

Variable Value
_csrf 'WVJw39Q6x_KHtv9xCdAlhJTe'
csrftoken 'c2ehey0WSYQQBGhsrDw2Cb84rjMEvYsiKgyewMfLH7oYGKfGF8HQGnVWeJWolNtx'
connect.sid 's%3A0voE9jUAO_AT8Wy3cj8hTpkMtj3qpn0K.9NqHXYtRyl%2FXC72KW91hS2M254%2FLuxNipGU7fwn8xC0'
sessionid 'vovvszqd3abrq0x07rqv42uahp6wp3df'
io 'CXqIpDUX8MD5KBOMAAAB'
wcsessionid 'to0chnkz1qgubv2uga7csiz230jbqu6j'
session 'eyJyZWRpciI6Ii8iLCJ1c2VyIjp7ImlkIjoiYWFhYWFhYWEtZ29vZC0wMDAwLTAwMDAtMDAwMDAwMDAwMDAwIiwidXNlcm5hbWUiOiJhbGljZSIsImVtYWlsIjoiYWxpY2UtdGhlLWFkbWluQHRlc3QuY29tIiwiaW1hZ2UiOiIvaW1nL2xvZ29zL3NtYWxsL3VzZXIucG5nIn19'
session.sig '0tKZ56-hzAlYR4mHNIHO7jLqzwE'

The only clear error appearing in the info is below:

SERVER_SOFTWARE 'gunicorn/19.3.0'
gunicorn.socket <socket.socket fd=10, family=AddressFamily.AF_INET, type=SocketKind.SOCK_STREAM, proto=0, laddr=('172.18.1.11', 8000), raddr=('172.18.1.15', 38980)>
wsgi.errors <gunicorn.http.wsgi.WSGIErrorsWrapper object at 0x7f02b2922e10>
wsgi.file_wrapper ''
wsgi.input <gunicorn.http.body.Body object at 0x7f02b2922a58>
wsgi.multiprocess True
wsgi.multithread False
wsgi.run_once False
wsgi.url_scheme 'http'
wsgi.version (1, 0)

where 172.18.1.11 is internal IP address of wirecloud and 172.18.1.15 is internal IP address of nginx.

Any idea?

Thanks

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions