Bug 974681 - puppet repo copy results in an unexpected error with some filter options
Summary: puppet repo copy results in an unexpected error with some filter options
Keywords:
Status: CLOSED UPSTREAM
Alias: None
Product: Pulp
Classification: Retired
Component: puppet-support
Version: 2.2 Beta
Hardware: Unspecified
OS: Unspecified
low
unspecified
Target Milestone: ---
: ---
Assignee: pulp-bugs
QA Contact: Preethi Thomas
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-06-14 19:38 UTC by Jeremy Cline
Modified: 2015-02-28 21:57 UTC (History)
3 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2015-02-28 21:57:09 UTC
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Pulp Redmine 358 0 None None None Never

Description Jeremy Cline 2013-06-14 19:38:25 UTC
Description of problem: When using 'pulp-admin puppet repo copy' an unexpected error occurs if the --gt, --lt, --gte, --lte, and --int-eq are used with non-integers.


Version-Release number of selected component (if applicable): pulp-puppet-admin-extensions-2.2.0-0.3.beta.fc18.noarch


How reproducible: always


Steps to Reproduce:
1. Create a repo and sync it. For example: pulp-admin puppet repo create --repo-id=puppet_repo --feed=http://forge.puppetlabs.com/ --queries httpd,mysql
2. pulp-admin puppet repo sync run --repo-id=puppet_repo
3. Create another puppet repo to copy to
4. pulp-admin puppet repo copy --from-repo-id=puppet_repo --to-repo-id=another_repo --int-eq='key=value'

Actual results:
An unexpected error has occurred. More information can be found in the client
log file ~/.pulp/admin.log.


Expected results:
A slightly more polite way of telling me I've made a huge mistake.

Additional info:
Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/pulp/client/extensions/core.py", line 478, in run
    exit_code = Cli.run(self, args)
  File "/usr/lib/python2.7/site-packages/okaara/cli.py", line 974, in run
    exit_code = command_or_section.execute(self.prompt, remaining_args)
  File "/usr/lib/python2.7/site-packages/pulp/client/extensions/extensions.py", line 224, in execute
    return self.method(*arg_list, **clean_kwargs)
  File "/usr/lib/python2.7/site-packages/pulp/client/commands/unit.py", line 82, in run
    override_config=override_config, **kwargs)
  File "/usr/lib/python2.7/site-packages/pulp/bindings/repository.py", line 386, in copy
    criteria = self._generate_search_criteria(**kwargs)
  File "/usr/lib/python2.7/site-packages/pulp/bindings/repository.py", line 313, in _generate_search_criteria
    'filters': {'unit': SearchAPI.compose_filters(**kwargs)},
  File "/usr/lib/python2.7/site-packages/pulp/bindings/search.py", line 135, in compose_filters
    clauses.extend(operator.compose_filters(raw_values))
  File "/usr/lib/python2.7/site-packages/pulp/bindings/search.py", line 44, in compose_filters
    value = self.value_parser(value)
ValueError: invalid literal for int() with base 10: 'value'

Comment 2 Chris Duryee 2014-11-12 01:49:15 UTC
This is still the case as of pulp 2.4.3.

Comment 3 Brian Bouterse 2015-02-28 21:57:09 UTC
Moved to https://pulp.plan.io/issues/358


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