Project

Profile

Help

Issue #1089

closed

pulp status call returning ISE 500

Added by paji@redhat.com over 9 years ago. Updated over 4 years ago.

Status:
CLOSED - CURRENTRELEASE
Priority:
Normal
Category:
-
Sprint/Milestone:
-
Start date:
Due date:
Estimated time:
Severity:
2. Medium
Version:
Master
Platform Release:
2.7.0
OS:
Triaged:
Yes
Groomed:
No
Sprint Candidate:
No
Tags:
Pulp 2
Sprint:
Quarter:

Description

on a machine with pulp-server-2.7.0-0.3.beta.el7.noarch run the following command

curl -k "https://<fqdn>/pulp/api/v2/status/"

Expected:
Ok

Actual:
{"http_request_method": "GET", "exception": ["AttributeError: 'dict' object has no attribute 'to_dict'\n"], "error_message": "'dict' object has no attribute 'to_dict'", "_href": "/pulp/api/v2/status/", "http_status": 500, "traceback": [" File \"/usr/lib/python2.7/site-packages/django/core/handlers/base.py\", line 112, in get_response\n response = wrapped_callback(request, *callback_args, **callback_kwargs)\n", " File \"/usr/lib/python2.7/site-packages/django/views/generic/base.py\", line 69, in view\n return self.dispatch(request, *args, **kwargs)\n", " File \"/usr/lib/python2.7/site-packages/django/views/generic/base.py\", line 87, in dispatch\n return handler(request, *args, **kwargs)\n", " File \"/usr/lib/python2.7/site-packages/pulp/server/webservices/views/status.py\", line 33, in get\n pulp_workers = [w.to_mongo().to_dict() for w in status_manager.get_workers()]\n"]}

Better trace:

Jun 24 18:00:29 katello-kant pulp: pulp.server.webservices.middleware.exception:ERROR: Unhandled Exception
Jun 24 18:00:29 katello-kant pulp: pulp.server.webservices.middleware.exception:ERROR: (6700-99680) 'dict' object has no attribute 'to_dict'
Jun 24 18:00:29 katello-kant pulp: pulp.server.webservices.middleware.exception:ERROR: (6700-99680) Traceback (most recent call last):
Jun 24 18:00:29 katello-kant pulp: pulp.server.webservices.middleware.exception:ERROR: (6700-99680) File "/usr/lib/python2.7/site-packages/django/core/handlers/base.py", line 112, in get_response
Jun 24 18:00:29 katello-kant pulp: pulp.server.webservices.middleware.exception:ERROR: (6700-99680) response = wrapped_callback(request, *callback_args, **callback_kwargs)
Jun 24 18:00:29 katello-kant pulp: pulp.server.webservices.middleware.exception:ERROR: (6700-99680) File "/usr/lib/python2.7/site-packages/django/views/generic/base.py", line 69, in view
Jun 24 18:00:29 katello-kant pulp: pulp.server.webservices.middleware.exception:ERROR: (6700-99680) return self.dispatch(request, *args, **kwargs)
Jun 24 18:00:29 katello-kant pulp: pulp.server.webservices.middleware.exception:ERROR: (6700-99680) File "/usr/lib/python2.7/site-packages/django/views/generic/base.py", line 87, in dispatch
Jun 24 18:00:29 katello-kant pulp: pulp.server.webservices.middleware.exception:ERROR: (6700-99680) return handler(request, *args, **kwargs)
Jun 24 18:00:29 katello-kant pulp: pulp.server.webservices.middleware.exception:ERROR: (6700-99680) File "/usr/lib/python2.7/site-packages/pulp/server/webservices/views/status.py", line 33, in get
Jun 24 18:00:29 katello-kant pulp: pulp.server.webservices.middleware.exception:ERROR: (6700-99680) pulp_workers = [w.to_mongo().to_dict() for w in status_manager.get_workers()]
Jun 24 18:00:29 katello-kant pulp: pulp.server.webservices.middleware.exception:ERROR: (6700-99680) AttributeError: 'dict' object has no attribute 'to_dict'

Other notes
This works

curl -k "https://<fqdn>/pulp/api/v2/status" vs curl -k "https://<fqdn>/pulp/api/v2/status/"

This trailing '/' may be a smell for other issues.


Related issues

Blocked by Pulp - Story #934: Update mongoengine dependency to 0.9CLOSED - CURRENTRELEASEbmbouter

Actions

Also available in: Atom PDF