Project

Profile

Help

Issue #3210

closed

Update Importer configuration fails.

Added by jortel@redhat.com over 6 years ago. Updated almost 3 years ago.

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

Description

Updating the importer config fails.

To recreate, PUT pulp/api/v2/repositories/<id>/importers/<id>/

produces the trace:

Dec 15 15:39:51 f25d.redhat.com pulp[20619]: celery.worker.job:ERROR: (20619-02688) Task pulp.server.managers.repo.importer.update_importer_config[8a2b6d45-1829-4560-b441-055e6adb56f3] raised unexpec
Dec 15 15:39:51 f25d.redhat.com pulp[20619]: celery.worker.job:ERROR: (20619-02688) Traceback (most recent call last):
Dec 15 15:39:51 f25d.redhat.com pulp[20619]: celery.worker.job:ERROR: (20619-02688)   File "/usr/lib/python2.7/site-packages/celery/app/trace.py", line 240, in trace_task
Dec 15 15:39:51 f25d.redhat.com pulp[20619]: celery.worker.job:ERROR: (20619-02688)     R = retval = fun(*args, **kwargs)
Dec 15 15:39:51 f25d.redhat.com pulp[20619]: celery.worker.job:ERROR: (20619-02688)   File "/home/jortel/git/pulp/server/pulp/server/async/tasks.py", line 529, in __call__
Dec 15 15:39:51 f25d.redhat.com pulp[20619]: celery.worker.job:ERROR: (20619-02688)     return super(Task, self).__call__(*args, **kwargs)
Dec 15 15:39:51 f25d.redhat.com pulp[20619]: celery.worker.job:ERROR: (20619-02688)   File "/home/jortel/git/pulp/server/pulp/server/async/tasks.py", line 107, in __call__
Dec 15 15:39:51 f25d.redhat.com pulp[20619]: celery.worker.job:ERROR: (20619-02688)     return super(PulpTask, self).__call__(*args, **kwargs)
Dec 15 15:39:51 f25d.redhat.com pulp[20619]: celery.worker.job:ERROR: (20619-02688)   File "/usr/lib/python2.7/site-packages/celery/app/trace.py", line 438, in __protected_call__
Dec 15 15:39:51 f25d.redhat.com pulp[20619]: celery.worker.job:ERROR: (20619-02688)     return self.run(*args, **kwargs)
Dec 15 15:39:51 f25d.redhat.com pulp[20619]: celery.worker.job:ERROR: (20619-02688)   File "/home/jortel/git/pulp/server/pulp/server/controllers/importer.py", line 277, in update_importer_config
Dec 15 15:39:51 f25d.redhat.com pulp[20619]: celery.worker.job:ERROR: (20619-02688)     repo_importer.save()
Dec 15 15:39:51 f25d.redhat.com pulp[20619]: celery.worker.job:ERROR: (20619-02688)   File "/home/jortel/git/pulp/server/pulp/server/db/model/__init__.py", line 291, in save
Dec 15 15:39:51 f25d.redhat.com pulp[20619]: celery.worker.job:ERROR: (20619-02688)     super(Importer, self).save()
Dec 15 15:39:51 f25d.redhat.com pulp[20619]: celery.worker.job:ERROR: (20619-02688)   File "/usr/lib/python2.7/site-packages/mongoengine/document.py", line 398, in save
Dec 15 15:39:51 f25d.redhat.com pulp[20619]: celery.worker.job:ERROR: (20619-02688)     raise OperationError(message % unicode(err))
Dec 15 15:39:51 f25d.redhat.com pulp[20619]: celery.worker.job:ERROR: (20619-02688) OperationError: Could not save document (Cannot update 'config' and 'config.feed' at the same time)

After some investigation, it seems to be data dependant. I tried various combinations of changing values and setting some to NULL which causes a dict.pop() but haven't found the magic combination yet.

This was found posting to update the OSTree importer but I'm convinced the problem is in the core. This PUT body reproduces is for me.

{
  "importer_config":{
    "basic_auth_username": null,
    "basic_auth_password": null,
    "depth":44,
    "feed":"http://xx"
  }
}

Also available in: Atom PDF