Bug 1288574

Summary: Incremental update should error out gracefully when invalid id is provided for errata/package/puppet module
Product: Red Hat Satellite Reporter: sthirugn <sthirugn>
Component: Errata ManagementAssignee: satellite6-bugs <satellite6-bugs>
Status: CLOSED DEFERRED QA Contact:
Severity: medium Docs Contact:
Priority: unspecified    
Version: 6.1.2CC: bbuckingham, bkearney, cwelton, pmoravec
Target Milestone: UnspecifiedKeywords: Triaged
Target Release: Unused   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-03-29 21:04:43 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:

Description sthirugn@redhat.com 2015-12-04 16:02:56 UTC
Description of problem:
Incremental update should error out gracefully when invalid id is provided for errata/package/puppet module

Version-Release number of selected component (if applicable):
Sat 6.1.5

How reproducible:
Always

Steps to Reproduce:
Attempt to do an incremental update with invalid puppet module id or package id or errata id.  The below example uses puppet module id:

# curl -k -H "Content-Type: application/json" -X POST -d  '{"description":"Testing incremental update", "add_content":{"puppet_module_ids":["bad_id"]},"content_view_version_environments":[{"environment_ids":["1"],"content_view_version_id": 19}]}' -u admin:changeme https://$sat6host/katello/api/content_view_versions/incremental_update

{"displayMessage":"undefined method `repositories' for nil:NilClass","errors":["undefined method `repositories' for nil:NilClass"]}


Actual results:
{"displayMessage":"undefined method `repositories' for nil:NilClass","errors":["undefined method `repositories' for nil:NilClass"]}

Expected results:
Proper error message should be displayed saying that the id is invalid.

Additional info:

Comment 3 Bryan Kearney 2017-03-29 21:04:43 UTC
Thank you for reporting this. Given our other priorities, I do not see us addressing this in the next few releases. I am therefore closing this out. If you feel that this is a mistake, please feel free to re-open with additional information. We appreciate your interest in Red Hat Satellite.