Bug 733705 - Need better error handling when trying to add filter to a file repo
Summary: Need better error handling when trying to add filter to a file repo
Alias: None
Product: Pulp
Classification: Retired
Component: user-experience
Version: unspecified
Hardware: Unspecified
OS: Unspecified
Target Milestone: ---
: Sprint 28
Assignee: Sayli Karmarkar
QA Contact: Preethi Thomas
Depends On:
TreeView+ depends on / blocked
Reported: 2011-08-26 14:42 UTC by Preethi Thomas
Modified: 2015-03-23 01:10 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Last Closed: 2012-02-24 20:15:48 UTC

Attachments (Terms of Use)

Description Preethi Thomas 2011-08-26 14:42:57 UTC
Description of problem:
Need better error handling when trying to add filter to a file repo

root@pulp-f15 ~]# pulp-admin repo add_filters --id=file_repo_local --filter white1
error: operation failed: TypeError: 'NoneType' object is not subscriptable
[root@pulp-f15 ~]# 

Version-Release number of selected component (if applicable):
[root@pulp-f15 ~]# rpm -q pulp

Comment 1 Preethi Thomas 2011-08-31 15:58:36 UTC
from pulp.log

2011-08-31 12:08:20,112 21115:140533510944512: pulp.server.webservices.controllers.decorators:ERROR: decorators:52 Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/pulp/server/webservices/controllers/decorators.py", line 48, in report_error
    return method(self, *args, **kwargs)
  File "/usr/lib/python2.7/site-packages/pulp/server/webservices/controllers/decorators.py", line 127, in _auth_decorator
    value = method(self, *args, **kwargs)
  File "/usr/lib/python2.7/site-packages/pulp/server/webservices/controllers/repositories.py", line 1360, in POST
    return action(id)
  File "/usr/lib/python2.7/site-packages/pulp/server/webservices/controllers/repositories.py", line 1265, in add_filters
    api.add_filters(id=id, filter_ids=data['filters'])
  File "/usr/lib/python2.7/site-packages/pulp/server/api/repo.py", line 1777, in add_filters
    raise PulpException("Filters can be added to repos with 'local' feed only")
PulpException: "Filters can be added to repos with 'local' feed only"

Comment 2 Jeff Ortel 2011-09-29 00:26:59 UTC
build: 0.235

Comment 3 Preethi Thomas 2011-09-29 14:35:11 UTC

[root@preethi ~]# rpm -q pulp

[root@preethi ~]# pulp-admin repo add_filters --id=file_repo --filter=white1
error: operation failed: PulpException: Filters can be added to repos with 'local' feed only

Comment 4 Preethi Thomas 2012-02-24 20:15:48 UTC
Pulp v1.0 is released
Closed Current Release.

Comment 5 Preethi Thomas 2012-02-24 20:17:23 UTC
Pulp v1.0 is released.

Note You need to log in before you can comment on or make changes to this bug.