Hide Forgot
Description of problem: Traceback when deleting filter through API [root@preethi ~]# curl -k -u admin:admin -X POST https://localhost/pulp/api/filters/blacklist/delete_filter/ "Traceback (most recent call last):\n File \"/usr/lib/python2.7/site-packages/pulp/server/webservices/controllers/decorators.py\", line 48, in report_error\n return method(self, *args, **kwargs)\n File \"/usr/lib/python2.7/site-packages/pulp/server/webservices/controllers/decorators.py\", line 127, in _auth_decorator\n value = method(self, *args, **kwargs)\n File \"/usr/lib/python2.7/site-packages/pulp/server/webservices/controllers/filters.py\", line 120, in delete_filter\n if data['force'] == 'true':\nKeyError: 'force'\n"[root@preethi ~]# Version-Release number of selected component (if applicable): [root@preethi ~]# rpm -q pulp pulp-0.0.251-1.fc15.noarch [root@preethi ~]#
Fixed. $ curl -k -u admin:admin -X POST https://localhost/pulp/api/filters/blacklist/delete_filter/ true
build: 0.254.
verified [root@preethi ~]# rpm -q pulp pulp-0.0.254-6.fc15.noarch [root@preethi ~]# pulp-admin filter list +------------------------------------------+ Available Filters +------------------------------------------+ Id : pulp Description : pulp Type : blacklist Package List : ['gofer'] [root@preethi ~]# curl -k -u admin:admin -X POST curl: no URL specified! curl: try 'curl --help' or 'curl --manual' for more information [root@preethi ~]# https://localhost/pulp/api/filters/blacklist/delete_filter/ -bash: https://localhost/pulp/api/filters/blacklist/delete_filter/: No such file or directory [root@preethi ~]# curl -k -u admin:admin -X POST https://localhost/pulp/api/filters/pulp/delete_filter/ "Traceback (most recent call last):\n File \"/usr/lib/python2.7/site-packages/pulp/server/webservices/controllers/decorators.py\", line 48, in report_error\n return method(self, *args, **kwargs)\n File \"/usr/lib/python2.7/site-packages/pulp/server/webservices/controllers/decorators.py\", line 127, in _auth_decorator\n value = method(self, *args, **kwargs)\n File \"/usr/lib/python2.7/site-packages/pulp/server/webservices/controllers/filters.py\", line 126, in delete_filter\n api.delete(id, force)\n File \"/usr/lib/python2.7/site-packages/pulp/server/api/filter.py\", line 70, in delete\n % (id, associated_repo_ids))\nPulpException: Filter [pulp] cannot be deleted because of it's association with following repos: [u'content-1']. You can use --force to force deletion of filter by removing it's association with repositories.\n"[root@preethi ~]# [root@preethi ~]# [root@preethi ~]# pulp-admin filter delete --id=pulp error: error: operation failed: PulpException: Filter [pulp] cannot be deleted because of it's association with following repos: [u'content-1']. You can use --force to force deletion of filter by removing it's association with repositories. [root@preethi ~]# curl -k -u admin:admin -X POST https://localhost/pulp/api/filters/pulp/delete_filter/ --force curl: option --force: is unknown curl: try 'curl --help' or 'curl --manual' for more information [root@preethi ~]# [root@preethi ~]# pulp-admin filter delete --id=content-1 error: error: operation failed: A filter with the id, content-1, does not exist [root@preethi ~]# pulp-admin repo delete --id=content-1 Successful deleted repository [ content-1 ] [root@preethi ~]# curl -k -u admin:admin -X POST https://localhost/pulp/api/filters/pulp/delete_filter/ true[root@preethi pulp-admin filter listNo filters available to list [root@preethi ~]#
Pulp v1.0 is released Closed Current Release.
Pulp v1.0 is released.