Project

Profile

Help

Issue #1501

Updating a distributor causes an HTTP 500

Added by rbarlow almost 5 years ago. Updated over 1 year ago.

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

Description

Credit goes to Adam Miller for finding and reporting this:

# pulp-admin docker repo update --repo-id=v2test --repo-registry-id=testing/v2test
This command may be exited via ctrl+c without affecting the request.

[-]
Running...
An internal error occurred on the Pulp server:

RequestException: GET request on
/pulp/api/v2/tasks/77c9fee3-baf8-4b84-9ea3-73139500d2c5/ failed with 500 -
<Distributor: Distributor object> is not JSON serializable

[root@maxamillion-pulp-test httpd]# pulp-admin docker repo update --repo-id=v2test --repo-registry-id=testing/v2test
This command may be exited via ctrl+c without affecting the request.

[-]
Running...
An internal error occurred on the Pulp server:

RequestException: GET request on
/pulp/api/v2/tasks/ca179d97-7d42-4135-a68a-cc850a122139/ failed with 500 -
<Distributor: Distributor object> is not JSON serializable

====================== LOGS =============================
Jan 08 22:45:06 maxamillion-pulp-test.novalocal pulp[11242]: pulp.plugins.loader.manager:INFO: Loaded plugin iso_importer for types: iso
Jan 08 22:45:06 maxamillion-pulp-test.novalocal pulp[11242]: pulp.plugins.loader.manager:INFO: Loaded plugin puppet_importer for types: puppet_module
Jan 08 22:45:06 maxamillion-pulp-test.novalocal pulp[11242]: pulp.plugins.loader.manager:INFO: Loaded plugin yum_profiler for types: rpm,erratum
Jan 08 22:45:06 maxamillion-pulp-test.novalocal pulp[11242]: pulp.plugins.loader.manager:INFO: Loaded plugin puppet_whole_repo_profiler for types: puppet_module
Jan 08 22:45:06 maxamillion-pulp-test.novalocal pulp[11242]: pulp.plugins.loader.manager:INFO: Loaded plugin yum for types: rpm
Jan 08 22:45:06 maxamillion-pulp-test.novalocal pulp[11242]: pulp.plugins.loader.manager:INFO: Loaded plugin rhui for types: rpm
Jan 08 22:45:06 maxamillion-pulp-test.novalocal pulp[11242]: gofer.messaging.adapter.qpid.connection:INFO: connecting: URL: tcp://localhost|SSL: ca: /etc/pki/qpid/ca/ca.crt|key: None|certificate: /etc/pki/qpid/client/client.pem|host-validation: False
Jan 08 22:45:06 maxamillion-pulp-test.novalocal pulp[11242]: gofer.messaging.adapter.qpid.connection:INFO: connected: tcp://localhost
Jan 08 22:45:06 maxamillion-pulp-test.novalocal pulp[11242]: gofer.messaging.adapter.qpid.connection:INFO: connecting: URL: tcp://localhost|SSL: ca: /etc/pki/qpid/ca/ca.crt|key: None|certificate: /etc/pki/qpid/client/client.pem|host-validation: False
Jan 08 22:45:06 maxamillion-pulp-test.novalocal pulp[11242]: pulp.server.agent.direct.services:INFO: Task reply handler, started.
Jan 08 22:45:06 maxamillion-pulp-test.novalocal pulp[11242]: pulp.server.agent.direct.services:INFO: AMQP reply handler started
Jan 08 22:45:06 maxamillion-pulp-test.novalocal pulp[11242]: pulp.server.webservices.application:INFO: *************************************************************
Jan 08 22:45:06 maxamillion-pulp-test.novalocal pulp[11242]: pulp.server.webservices.application:INFO: The Pulp server has been successfully initialized
Jan 08 22:45:06 maxamillion-pulp-test.novalocal pulp[11242]: pulp.server.webservices.application:INFO: *************************************************************
Jan 08 22:45:06 maxamillion-pulp-test.novalocal pulp[11242]: gofer.messaging.adapter.qpid.connection:INFO: connected: tcp://localhost
Jan 08 23:18:09 maxamillion-pulp-test.novalocal pulp[11242]: kombu.transport.qpid:INFO: Connected to qpid with SASL mechanism ANONYMOUS
Jan 08 23:18:11 maxamillion-pulp-test.novalocal pulp[11240]: pulp.server.webservices.middleware.exception:ERROR: Unhandled Exception
Jan 08 23:18:11 maxamillion-pulp-test.novalocal pulp[11240]: pulp.server.webservices.middleware.exception:ERROR: (11240-42688) <Distributor: Distributor object> is not JSON serializable
Jan 08 23:18:11 maxamillion-pulp-test.novalocal pulp[11240]: pulp.server.webservices.middleware.exception:ERROR: (11240-42688) Traceback (most recent call last):
Jan 08 23:18:11 maxamillion-pulp-test.novalocal pulp[11240]: pulp.server.webservices.middleware.exception:ERROR: (11240-42688)   File "/usr/lib/python2.7/site-packages/django/core/handlers/base.py", line 132, in get_response
Jan 08 23:18:11 maxamillion-pulp-test.novalocal pulp[11240]: pulp.server.webservices.middleware.exception:ERROR: (11240-42688)     response = wrapped_callback(request, *callback_args, **callback_kwargs)
Jan 08 23:18:11 maxamillion-pulp-test.novalocal pulp[11240]: pulp.server.webservices.middleware.exception:ERROR: (11240-42688)   File "/usr/lib/python2.7/site-packages/django/views/generic/base.py", line 71, in view
Jan 08 23:18:11 maxamillion-pulp-test.novalocal pulp[11240]: pulp.server.webservices.middleware.exception:ERROR: (11240-42688)     return self.dispatch(request, *args, **kwargs)
Jan 08 23:18:11 maxamillion-pulp-test.novalocal pulp[11240]: pulp.server.webservices.middleware.exception:ERROR: (11240-42688)   File "/usr/lib/python2.7/site-packages/django/views/generic/base.py", line 89, in dispatch
Jan 08 23:18:11 maxamillion-pulp-test.novalocal pulp[11240]: pulp.server.webservices.middleware.exception:ERROR: (11240-42688)     return handler(request, *args, **kwargs)
Jan 08 23:18:11 maxamillion-pulp-test.novalocal pulp[11240]: pulp.server.webservices.middleware.exception:ERROR: (11240-42688)   File "/usr/lib/python2.7/site-packages/pulp/server/webservices/views/decorators.py", line 241, in _auth_decorator
Jan 08 23:18:11 maxamillion-pulp-test.novalocal pulp[11240]: pulp.server.webservices.middleware.exception:ERROR: (11240-42688)     return _verify_auth(self, operation, super_user_only, method, *args, **kwargs)
Jan 08 23:18:11 maxamillion-pulp-test.novalocal pulp[11240]: pulp.server.webservices.middleware.exception:ERROR: (11240-42688)   File "/usr/lib/python2.7/site-packages/pulp/server/webservices/views/decorators.py", line 195, in _verify_auth
Jan 08 23:18:11 maxamillion-pulp-test.novalocal pulp[11240]: pulp.server.webservices.middleware.exception:ERROR: (11240-42688)     value = method(self, *args, **kwargs)
Jan 08 23:18:11 maxamillion-pulp-test.novalocal pulp[11240]: pulp.server.webservices.middleware.exception:ERROR: (11240-42688)   File "/usr/lib/python2.7/site-packages/pulp/server/webservices/views/tasks.py", line 132, in get
Jan 08 23:18:11 maxamillion-pulp-test.novalocal pulp[11240]: pulp.server.webservices.middleware.exception:ERROR: (11240-42688)     return generate_json_response_with_pulp_encoder(task_dict)
Jan 08 23:18:11 maxamillion-pulp-test.novalocal pulp[11240]: pulp.server.webservices.middleware.exception:ERROR: (11240-42688)   File "/usr/lib/python2.7/site-packages/pulp/server/webservices/views/util.py", line 52, in generate_json_response
Jan 08 23:18:11 maxamillion-pulp-test.novalocal pulp[11240]: pulp.server.webservices.middleware.exception:ERROR: (11240-42688)     json_obj = json.dumps(content, default=default)
Jan 08 23:18:11 maxamillion-pulp-test.novalocal pulp[11240]: pulp.server.webservices.middleware.exception:ERROR: (11240-42688)   File "/usr/lib64/python2.7/json/__init__.py", line 250, in dumps
Jan 08 23:18:11 maxamillion-pulp-test.novalocal pulp[11240]: pulp.server.webservices.middleware.exception:ERROR: (11240-42688)     sort_keys=sort_keys, **kw).encode(obj)
Jan 08 23:18:11 maxamillion-pulp-test.novalocal pulp[11240]: pulp.server.webservices.middleware.exception:ERROR: (11240-42688)   File "/usr/lib64/python2.7/json/encoder.py", line 207, in encode
Jan 08 23:18:11 maxamillion-pulp-test.novalocal pulp[11240]: pulp.server.webservices.middleware.exception:ERROR: (11240-42688)     chunks = self.iterencode(o, _one_shot=True)
Jan 08 23:18:11 maxamillion-pulp-test.novalocal pulp[11240]: pulp.server.webservices.middleware.exception:ERROR: (11240-42688)   File "/usr/lib64/python2.7/json/encoder.py", line 270, in iterencode
Jan 08 23:18:11 maxamillion-pulp-test.novalocal pulp[11240]: pulp.server.webservices.middleware.exception:ERROR: (11240-42688)     return _iterencode(o, 0)
Jan 08 23:18:11 maxamillion-pulp-test.novalocal pulp[11240]: pulp.server.webservices.middleware.exception:ERROR: (11240-42688)   File "/usr/lib/python2.7/site-packages/pulp/server/webservices/views/util.py", line 30, in pulp_json_encoder
Jan 08 23:18:11 maxamillion-pulp-test.novalocal pulp[11240]: pulp.server.webservices.middleware.exception:ERROR: (11240-42688)     return json_util.default(obj)
Jan 08 23:18:11 maxamillion-pulp-test.novalocal pulp[11240]: pulp.server.webservices.middleware.exception:ERROR: (11240-42688)   File "/usr/lib64/python2.7/site-packages/bson/json_util.py", line 256, in default
Jan 08 23:18:11 maxamillion-pulp-test.novalocal pulp[11240]: pulp.server.webservices.middleware.exception:ERROR: (11240-42688)     raise TypeError("%%r is not JSON serializable" %% obj)
Jan 08 23:18:11 maxamillion-pulp-test.novalocal pulp[11240]: pulp.server.webservices.middleware.exception:ERROR: (11240-42688) TypeError: <Distributor: Distributor object> is not JSON serializable
Jan 08 23:18:24 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: Unhandled Exception
Jan 08 23:18:24 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-17664) <Distributor: Distributor object> is not JSON serializable
Jan 08 23:18:24 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-17664) Traceback (most recent call last):
Jan 08 23:18:24 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-17664)   File "/usr/lib/python2.7/site-packages/django/core/handlers/base.py", line 132, in get_response
Jan 08 23:18:24 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-17664)     response = wrapped_callback(request, *callback_args, **callback_kwargs)
Jan 08 23:18:24 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-17664)   File "/usr/lib/python2.7/site-packages/django/views/generic/base.py", line 71, in view
Jan 08 23:18:24 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-17664)     return self.dispatch(request, *args, **kwargs)
Jan 08 23:18:24 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-17664)   File "/usr/lib/python2.7/site-packages/django/views/generic/base.py", line 89, in dispatch
Jan 08 23:18:24 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-17664)     return handler(request, *args, **kwargs)
Jan 08 23:18:24 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-17664)   File "/usr/lib/python2.7/site-packages/pulp/server/webservices/views/decorators.py", line 241, in _auth_decorator
Jan 08 23:18:24 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-17664)     return _verify_auth(self, operation, super_user_only, method, *args, **kwargs)
Jan 08 23:18:24 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-17664)   File "/usr/lib/python2.7/site-packages/pulp/server/webservices/views/decorators.py", line 195, in _verify_auth
Jan 08 23:18:24 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-17664)     value = method(self, *args, **kwargs)
Jan 08 23:18:24 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-17664)   File "/usr/lib/python2.7/site-packages/pulp/server/webservices/views/tasks.py", line 132, in get
Jan 08 23:18:24 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-17664)     return generate_json_response_with_pulp_encoder(task_dict)
Jan 08 23:18:24 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-17664)   File "/usr/lib/python2.7/site-packages/pulp/server/webservices/views/util.py", line 52, in generate_json_response
Jan 08 23:18:24 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-17664)     json_obj = json.dumps(content, default=default)
Jan 08 23:18:24 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-17664)   File "/usr/lib64/python2.7/json/__init__.py", line 250, in dumps
Jan 08 23:18:24 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-17664)     sort_keys=sort_keys, **kw).encode(obj)
Jan 08 23:18:24 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-17664)   File "/usr/lib64/python2.7/json/encoder.py", line 207, in encode
Jan 08 23:18:24 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-17664)     chunks = self.iterencode(o, _one_shot=True)
Jan 08 23:18:24 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-17664)   File "/usr/lib64/python2.7/json/encoder.py", line 270, in iterencode
Jan 08 23:18:24 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-17664)     return _iterencode(o, 0)
Jan 08 23:18:24 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-17664)   File "/usr/lib/python2.7/site-packages/pulp/server/webservices/views/util.py", line 30, in pulp_json_encoder
Jan 08 23:18:24 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-17664)     return json_util.default(obj)
Jan 08 23:18:24 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-17664)   File "/usr/lib64/python2.7/site-packages/bson/json_util.py", line 256, in default
Jan 08 23:18:24 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-17664)     raise TypeError("%%r is not JSON serializable" %% obj)
Jan 08 23:18:24 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-17664) TypeError: <Distributor: Distributor object> is not JSON serializable
Jan 11 14:52:49 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: Unhandled Exception
Jan 11 14:52:49 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-03072) <Distributor: Distributor object> is not JSON serializable
Jan 11 14:52:49 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-03072) Traceback (most recent call last):
Jan 11 14:52:49 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-03072)   File "/usr/lib/python2.7/site-packages/django/core/handlers/base.py", line 132, in get_response
Jan 11 14:52:49 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-03072)     response = wrapped_callback(request, *callback_args, **callback_kwargs)
Jan 11 14:52:49 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-03072)   File "/usr/lib/python2.7/site-packages/django/views/generic/base.py", line 71, in view
Jan 11 14:52:49 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-03072)     return self.dispatch(request, *args, **kwargs)
Jan 11 14:52:49 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-03072)   File "/usr/lib/python2.7/site-packages/django/views/generic/base.py", line 89, in dispatch
Jan 11 14:52:49 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-03072)     return handler(request, *args, **kwargs)
Jan 11 14:52:49 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-03072)   File "/usr/lib/python2.7/site-packages/pulp/server/webservices/views/decorators.py", line 241, in _auth_decorator
Jan 11 14:52:49 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-03072)     return _verify_auth(self, operation, super_user_only, method, *args, **kwargs)
Jan 11 14:52:49 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-03072)   File "/usr/lib/python2.7/site-packages/pulp/server/webservices/views/decorators.py", line 195, in _verify_auth
Jan 11 14:52:49 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-03072)     value = method(self, *args, **kwargs)
Jan 11 14:52:49 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-03072)   File "/usr/lib/python2.7/site-packages/pulp/server/webservices/views/tasks.py", line 132, in get
Jan 11 14:52:49 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-03072)     return generate_json_response_with_pulp_encoder(task_dict)
Jan 11 14:52:49 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-03072)   File "/usr/lib/python2.7/site-packages/pulp/server/webservices/views/util.py", line 52, in generate_json_response
Jan 11 14:52:49 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-03072)     json_obj = json.dumps(content, default=default)
Jan 11 14:52:49 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-03072)   File "/usr/lib64/python2.7/json/__init__.py", line 250, in dumps
Jan 11 14:52:49 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-03072)     sort_keys=sort_keys, **kw).encode(obj)
Jan 11 14:52:49 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-03072)   File "/usr/lib64/python2.7/json/encoder.py", line 207, in encode
Jan 11 14:52:49 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-03072)     chunks = self.iterencode(o, _one_shot=True)
Jan 11 14:52:49 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-03072)   File "/usr/lib64/python2.7/json/encoder.py", line 270, in iterencode
Jan 11 14:52:49 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-03072)     return _iterencode(o, 0)
Jan 11 14:52:49 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-03072)   File "/usr/lib/python2.7/site-packages/pulp/server/webservices/views/util.py", line 30, in pulp_json_encoder
Jan 11 14:52:49 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-03072)     return json_util.default(obj)
Jan 11 14:52:49 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-03072)   File "/usr/lib64/python2.7/site-packages/bson/json_util.py", line 256, in default
Jan 11 14:52:49 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-03072)     raise TypeError("%%r is not JSON serializable" %% obj)
Jan 11 14:52:49 maxamillion-pulp-test.novalocal pulp[11241]: pulp.server.webservices.middleware.exception:ERROR: (11241-03072) TypeError: <Distributor: Distributor object> is not JSON serializable

Associated revisions

Revision aeb2ec24 View on GitHub
Added by Austin Macdonald almost 5 years ago

Serialize distributor before passing to task

closes #1501

Revision aeb2ec24 View on GitHub
Added by Austin Macdonald almost 5 years ago

Serialize distributor before passing to task

closes #1501

History

#1 Updated by amacdona@redhat.com almost 5 years ago

  • Status changed from NEW to ASSIGNED
  • Assignee set to amacdona@redhat.com
  • Platform Release set to 2.8.0
  • Triaged changed from No to Yes

#2 Updated by amacdona@redhat.com almost 5 years ago

  • Status changed from ASSIGNED to POST

#3 Updated by amacdona@redhat.com almost 5 years ago

  • Status changed from POST to MODIFIED

#4 Updated by dkliban@redhat.com almost 5 years ago

  • Status changed from MODIFIED to 5

#5 Updated by dkliban@redhat.com over 4 years ago

  • Status changed from 5 to CLOSED - CURRENTRELEASE

#6 Updated by bmbouter over 1 year ago

  • Tags Pulp 2 added

Please register to edit this issue

Also available in: Atom PDF