Bug 1356111
Summary: | [upgrade] repository.distributor_update task failed with error: KeyError(u'repo-registry-id',) | ||||||
---|---|---|---|---|---|---|---|
Product: | Red Hat Satellite | Reporter: | Sachin Ghai <sghai> | ||||
Component: | Pulp | Assignee: | satellite6-bugs <satellite6-bugs> | ||||
Status: | CLOSED ERRATA | QA Contact: | Sachin Ghai <sghai> | ||||
Severity: | medium | Docs Contact: | |||||
Priority: | unspecified | ||||||
Version: | Unspecified | CC: | bbuckingham, bmbouter, daviddavis, dkliban, ggainey, ipanova, jcallaha, jsherril, mhrivnak, pcreech, rchan, ttereshc | ||||
Target Milestone: | Unspecified | Keywords: | Triaged | ||||
Target Release: | Unused | ||||||
Hardware: | Unspecified | ||||||
OS: | Unspecified | ||||||
Whiteboard: | |||||||
Fixed In Version: | Doc Type: | If docs needed, set a value | |||||
Doc Text: | Story Points: | --- | |||||
Clone Of: | Environment: | ||||||
Last Closed: | 2018-02-21 17:00:35 UTC | Type: | Bug | ||||
Regression: | --- | Mount Type: | --- | ||||
Documentation: | --- | CRM: | |||||
Verified Versions: | Category: | --- | |||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
Cloudforms Team: | --- | Target Upstream Version: | |||||
Embargoed: | |||||||
Attachments: |
|
Description
Sachin Ghai
2016-07-13 12:37:26 UTC
Created attachment 1179238 [details]
complete exception
Michael, any thoughts on what may cause the above exception and the impacts it may have? This task 'add_export_distributor' is attempting to add an export distributor to our yum repos. As part of that process it does a full 'refresh' of the repository, updating the importers and distributors of all repos if they are not exactly what we expect. Judging by the traceback: File "/usr/lib/python2.7/site-packages/pulp/server/controllers/distributor.py", line 211, in update I'm guessing this was a distributor update, and by the error containing 'repo-registry-id' it was a docker repo. Here is what I think is going on, but it would be helpful to have feedback from the katello side on whether it sounds right. It appears that the distributor config is being updated, and that in the new config object being provided, the key "repo-registry-id" has a value of None. Here is what the REST API docs say about values of None in that case: "any value that is set to explicitly to None will be removed from the config." It appears that the corresponding code in pulp assumes that if a key has a value of None in the new config, it must be present in the old config, and then tries to remove it. Apparently in this case, katello includes "repo-registry-id: None" in the new config, but the old one didn't contain that key, so it is resulting in an unhandled exception. Ideally pulp should tolerate this condition. I'll file an upstream bug on it. Do you think I'm right about what katello is doing? Is katello deliberately trying to remove the repo-registry-id setting from distributor configs? Michael, It does seem that that is the problem. The odd thing is that pulp does not return any error at all, just logs the exception (so this bz isn't really fatal at all). It seems we always passing repo-registry-id as None no matter what on creation and update. I'm not sure why, but it was added explicitly at some point. The Pulp upstream bug status is at NEW. Updating the external tracker on this bug. The Pulp upstream bug priority is at Normal. Updating the external tracker on this bug. The Pulp upstream bug status is at CLOSED - CURRENTRELEASE. Updating the external tracker on this bug. The Pulp upstream bug priority is at High. Updating the external tracker on this bug. All upstream Pulp bugs are at MODIFIED+. Moving this bug to POST. Verified with upgrade from 6.2.12 -> sat6.3 snap24. The reported error KeyError: u'repo-registry-id' no longer reproducible. Moving to verified. Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHSA-2018:0336 |