Bug 988005 - uploads group failing
uploads group failing
Status: CLOSED CURRENTRELEASE
Product: Pulp
Classification: Community
Component: rpm-support (Show other bugs)
2.2 Beta
Unspecified Unspecified
unspecified Severity unspecified
: ---
: 2.2.0
Assigned To: Michael Hrivnak
Preethi Thomas
: Triaged
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2013-07-24 10:15 EDT by Preethi Thomas
Modified: 2013-09-10 11:43 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-09-10 11:43:05 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Preethi Thomas 2013-07-24 10:15:23 EDT
Description of problem:

Trying create a package grop with repo uploads group is failing
Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
[root@mgmt12 ~]# pulp-admin rpm repo uploads group --repo-id upload --group-id pulp-test --name pulp-test --description "test group"
+----------------------------------------------------------------------+
                              Unit Upload
+----------------------------------------------------------------------+

Extracting necessary metadata for each request...
... completed

Creating upload requests on the server...
[==================================================] 100%
Initializing upload
... completed

Starting upload of selected units. If this process is stopped through ctrl+c,
the uploads will be paused and may be resumed later using the resume command or
cancelled entirely using the cancel command.

Importing into the repository...
The web server reported an error trying to access the Pulp application. The
likely cause is that the pulp-manage-db script has not been run prior to
starting the server. More information can be found in Apache's error log file on
the server itself.



Actual results:


Expected results:


Additional info:

2013-07-24 10:05:05,410 pulp.server.managers.content.upload:ERROR: Error from the importer while importing uploaded unit to repository [upload]
Traceback (most recent call last):
  File "/usr/lib/python2.6/site-packages/pulp/server/managers/content/upload.py", line 227, in import_uploaded_unit
    importer_instance.upload_unit(transfer_repo, unit_type_id, unit_key, unit_metadata, file_path, conduit, call_config)
  File "/usr/lib/python2.6/site-packages/pulp_rpm/plugins/importers/yum/importer.py", line 71, in upload_unit
    return upload.upload(repo, type_id, unit_key, metadata, file_path, conduit, config)
  File "/usr/lib/python2.6/site-packages/pulp_rpm/plugins/importers/yum/upload.py", line 83, in upload
    _update_provides_requires(model)
  File "/usr/lib/python2.6/site-packages/pulp_rpm/plugins/importers/yum/upload.py", line 114, in _update_provides_requires
    model.metadata['repodata']['primary'].encode(codec)
KeyError: 'repodata'
2013-07-24 10:05:05,411 pulp.server.dispatch.task:ERROR: Pulp exception occurred: PulpExecutionException
Traceback (most recent call last):
  File "/usr/lib/python2.6/site-packages/pulp/server/dispatch/task.py", line 138, in _run
    result = call(*args, **kwargs)
  File "/usr/lib/python2.6/site-packages/pulp/server/managers/content/upload.py", line 227, in import_uploaded_unit
    importer_instance.upload_unit(transfer_repo, unit_type_id, unit_key, unit_metadata, file_path, conduit, call_config)
  File "/usr/lib/python2.6/site-packages/pulp_rpm/plugins/importers/yum/importer.py", line 71, in upload_unit
    return upload.upload(repo, type_id, unit_key, metadata, file_path, conduit, config)
  File "/usr/lib/python2.6/site-packages/pulp_rpm/plugins/importers/yum/upload.py", line 83, in upload
    _update_provides_requires(model)
  File "/usr/lib/python2.6/site-packages/pulp_rpm/plugins/importers/yum/upload.py", line 114, in _update_provides_requires
    model.metadata['repodata']['primary'].encode(codec)
PulpExecutionException: Pulp exception occurred: PulpExecutionException
2013-07-24 10:05:05,412 pulp.server.dispatch.task:INFO: FAILURE: Task 01b1068c-c1a4-403f-a6de-c5c3a069a5ad: CallRequest: ContentUploadManager.import_uploaded_unit(u'upload', 'package_group', {'repo_id': 'upload', 'id': 'pulp-test'}, {'mandatory_package_names': None, 'name': 'pulp-test', 'default': False, 'display_order': 0, 'user_visible': False, 'translated_name': '', 'conditional_package_names': [], 'translated_description': {}, 'optional_package_names': None, 'default_package_names': None, 'langonly': None, 'description': 'test group'}, '529be992-9ddc-46f4-9478-46ba55411845')
2013-07-24 10:05:05,468 pulp.server.webservices.middleware.exception:ERROR: Pulp exception occurred: PulpExecutionException
Traceback (most recent call last):
  File "/usr/lib/python2.6/site-packages/pulp/server/webservices/middleware/exception.py", line 44, in __call__
    return self.app(environ, start_response)
  File "/usr/lib/python2.6/site-packages/pulp/server/webservices/middleware/postponed.py", line 39, in __call__
    return self.app(environ, start_response)
  File "/usr/lib/python2.6/site-packages/web/application.py", line 279, in wsgi
    result = self.handle_with_processors()
  File "/usr/lib/python2.6/site-packages/pulp/server/webservices/application.py", line 26, in _handle_with_processors
    return process(self.processors)
  File "/usr/lib/python2.6/site-packages/pulp/server/webservices/application.py", line 23, in process
    return p(lambda : process(processors))
  File "/usr/lib/python2.6/site-packages/web/application.py", line 566, in processor
    return handler()
  File "/usr/lib/python2.6/site-packages/pulp/server/webservices/application.py", line 23, in <lambda>
    return p(lambda : process(processors))
  File "/usr/lib/python2.6/site-packages/pulp/server/webservices/application.py", line 23, in process
    return p(lambda : process(processors))
  File "/usr/lib/python2.6/site-packages/web/application.py", line 581, in processor
    result = handler()
  File "/usr/lib/python2.6/site-packages/pulp/server/webservices/application.py", line 23, in <lambda>
    return p(lambda : process(processors))
  File "/usr/lib/python2.6/site-packages/pulp/server/webservices/application.py", line 25, in process
    return self.handle()
  File "/usr/lib/python2.6/site-packages/web/application.py", line 230, in handle
    return self._delegate(fn, self.fvars, args)
  File "/usr/lib/python2.6/site-packages/web/application.py", line 422, in _delegate
    return f()
  File "/usr/lib/python2.6/site-packages/web/application.py", line 430, in <lambda>
    f = lambda: self._delegate_sub_application(pat, what)
  File "/usr/lib/python2.6/site-packages/web/application.py", line 455, in _delegate_sub_application
    return app.handle_with_processors()
  File "/usr/lib/python2.6/site-packages/pulp/server/webservices/application.py", line 26, in _handle_with_processors
    return process(self.processors)
  File "/usr/lib/python2.6/site-packages/pulp/server/webservices/application.py", line 23, in process
    return p(lambda : process(processors))
  File "/usr/lib/python2.6/site-packages/web/application.py", line 566, in processor
    return handler()
  File "/usr/lib/python2.6/site-packages/pulp/server/webservices/application.py", line 23, in <lambda>
    return p(lambda : process(processors))
  File "/usr/lib/python2.6/site-packages/pulp/server/webservices/application.py", line 23, in process
    return p(lambda : process(processors))
  File "/usr/lib/python2.6/site-packages/web/application.py", line 581, in processor
    result = handler()
  File "/usr/lib/python2.6/site-packages/pulp/server/webservices/application.py", line 23, in <lambda>
    return p(lambda : process(processors))
  File "/usr/lib/python2.6/site-packages/pulp/server/webservices/application.py", line 25, in process
    return self.handle()
  File "/usr/lib/python2.6/site-packages/web/application.py", line 230, in handle
    return self._delegate(fn, self.fvars, args)
  File "/usr/lib/python2.6/site-packages/web/application.py", line 420, in _delegate
    return handle_class(cls)
  File "/usr/lib/python2.6/site-packages/web/application.py", line 396, in handle_class
    return tocall(*args)
  File "/usr/lib/python2.6/site-packages/pulp/server/webservices/controllers/decorators.py", line 227, in _auth_decorator
    value = method(self, *args, **kwargs)
  File "/usr/lib/python2.6/site-packages/pulp/server/webservices/controllers/repositories.py", line 949, in POST
    execution.execute(call_request)
  File "/usr/lib/python2.6/site-packages/pulp/server/dispatch/task.py", line 138, in _run
    result = call(*args, **kwargs)
  File "/usr/lib/python2.6/site-packages/pulp/server/managers/content/upload.py", line 227, in import_uploaded_unit
    importer_instance.upload_unit(transfer_repo, unit_type_id, unit_key, unit_metadata, file_path, conduit, call_config)
  File "/usr/lib/python2.6/site-packages/pulp_rpm/plugins/importers/yum/importer.py", line 71, in upload_unit
    return upload.upload(repo, type_id, unit_key, metadata, file_path, conduit, config)
  File "/usr/lib/python2.6/site-packages/pulp_rpm/plugins/importers/yum/upload.py", line 83, in upload
    _update_provides_requires(model)
  File "/usr/lib/python2.6/site-packages/pulp_rpm/plugins/importers/yum/upload.py", line 114, in _update_provides_requires
    model.metadata['repodata']['primary'].encode(codec)
PulpExecutionException: Pulp exception occurred: PulpExecutionException
Comment 1 Preethi Thomas 2013-07-24 10:29:44 EDT
Seeing the same error for category as well

[root@mgmt12 ~]# pulp-admin rpm repo uploads category --repo-id upload --category-id pulp-test --name pulp-test --description pulp-test-category --display-order 1 -v
+----------------------------------------------------------------------+
                              Unit Upload
+----------------------------------------------------------------------+

Extracting necessary metadata for each request...
... completed

Creating upload requests on the server...
[==================================================] 100%
Initializing upload
... completed

Starting upload of selected units. If this process is stopped through ctrl+c,
the uploads will be paused and may be resumed later using the resume command or
cancelled entirely using the cancel command.

Importing into the repository...
The web server reported an error trying to access the Pulp application. The
likely cause is that the pulp-manage-db script has not been run prior to
starting the server. More information can be found in Apache's error log file on
the server itself.

[root@mgmt12 ~]#
Comment 2 Michael Hrivnak 2013-07-25 18:15:23 EDT
https://github.com/pulp/pulp_rpm/pull/284
Comment 3 Jeff Ortel 2013-07-26 19:09:06 EDT
build: 2.2.0-0.22.beta
Comment 4 Preethi Thomas 2013-08-06 13:54:55 EDT
verified
[root@cloud-qe-14 ~]# rpm -q pulp-server
pulp-server-2.2.0-0.24.beta.el6.noarch
[root@cloud-qe-14 ~]# 

[root@cloud-qe-14 ~]# pulp-admin rpm repo uploads group --repo-id repo --group-id pulp-test --name pulp-test --description "test group"
+----------------------------------------------------------------------+
                              Unit Upload
+----------------------------------------------------------------------+

Extracting necessary metadata for each request...
... completed

Creating upload requests on the server...
[==================================================] 100%
Initializing upload
... completed

Starting upload of selected units. If this process is stopped through ctrl+c,
the uploads will be paused and may be resumed later using the resume command or
cancelled entirely using the cancel command.

Importing into the repository...
... completed

Deleting the upload request...
... completed

[root@cloud-qe-14 ~]#  pulp-admin rpm repo uploads category --repo-id repo --category-id pulp-test --name pulp-test --description pulp-test-category --display-order 1 -v
+----------------------------------------------------------------------+
                              Unit Upload
+----------------------------------------------------------------------+

Extracting necessary metadata for each request...
... completed

Creating upload requests on the server...
[==================================================] 100%
Initializing upload
... completed

Starting upload of selected units. If this process is stopped through ctrl+c,
the uploads will be paused and may be resumed later using the resume command or
cancelled entirely using the cancel command.

Importing into the repository...
... completed

Deleting the upload request...
... completed
Comment 5 Preethi Thomas 2013-09-10 11:43:05 EDT
2.2 released
http://repos.fedorapeople.org/repos/pulp/pulp/stable/2.2/

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