Red Hat Bugzilla – Bug 1359665
Content-view filter and content-view update cmds should not requires --organization-id or --organization option
Last modified: 2018-08-31 11:19 EDT
Description of problem: In ou automation we saw that bunch of cv filter and CV update tests are failing with below error: Error: Could not find organization, please set one of options --organization, --organization-label, --organization-id. Earlier, automation was executing those tests without this error. I tried those tests manually and found same error like: Create CV filter requires --organization/--organization-label/--organization-id. ---- ~]# hammer -v -u admin -p changeme --output=csv content-view filter create --type="rpm" --content-view-id="1" --name="test" --inclusion="true" [ERROR 2016-07-25 01:57:53 Exception] Error: Could not find organization, please set one of options --organization, --organization-label, --organization-id. Could not create the filter: Error: Could not find organization, please set one of options --organization, --organization-label, --organization-id. ----- with --organization-id it was created. However, I think it should be created without passing --organization-id option since we are passing cv id. ~]# hammer -v -u admin -p changeme --output=csv content-view filter create --type="rpm" --content-view-id="1" --name="test" --inclusion="true" --organization-id=1 Message,Id,Name Filter created,1,test Similar issue with following cmds: - content-view update - cv filter create/update/delete 2016-07-23 17:52:31 - robottelo.ssh - DEBUG - >>> [qe-sat6-rhel6.satqe.lab.eng.rdu2.redhat.com] LANG=en_US.UTF-8 hammer -v -u admin -p changeme --output=csv content-view update --component-ids="327" --id="355" 2016-07-23 17:52:31 - robottelo.ssh - INFO - Instantiated Paramiko client 0x7f698efcfcd0 2016-07-23 17:52:33 - robottelo.ssh - INFO - Destroying Paramiko client 0x7f698efcfcd0 2016-07-23 17:52:33 - robottelo.ssh - INFO - Destroyed Paramiko client 0x7f698efcfcd0 2016-07-23 17:52:33 - robottelo.ssh - DEBUG - <<< stderr [ERROR 2016-07-23 17:52:33 Exception] Error: Could not find organization, please set one of options --organization, --organization-label, --organization-id. Could not update the content view: Error: Could not find organization, please set one of options --organization, --organization-label, --organization-id. [ERROR 2016-07-23 17:52:33 Exception] Version-Release number of selected component (if applicable): sat62 GA snap21.1 RC build How reproducible: Steps to Reproduce: 1. 2. 3. Actual results: cv filter create/update/delete cmds requires --organization-id option Expected results: --organization-id was not required earlier. Moreover when user is passing CV-id then explicitly --organization/otganization-id option should not be required. similar issue is with cv update, why user need to pass --organization-id Additional info:
Is this generic hammer or content specific bug?
It is content specific, probably related to the bugs mentioned in c#1
Created redmine issue http://projects.theforeman.org/issues/15889 from this bug
Verified in Satellite 6.2.1 [root@ibm-x3550m3-10 puppet]# hammer -v --output=csv content-view filter create --type="rpm" --content-view-id="1" --name="test" --inclusion="true" Message,Id,Name Filter created,1,test
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/RHBA-2016:1615