Bug 1093169 - Upload resume fails ungracefully if the file to be uploaded has been removed
Summary: Upload resume fails ungracefully if the file to be uploaded has been removed
Keywords:
Status: CLOSED UPSTREAM
Alias: None
Product: Pulp
Classification: Retired
Component: rpm-support
Version: Master
Hardware: All
OS: Linux
low
low
Target Milestone: ---
: ---
Assignee: pulp-bugs
QA Contact: pulp-qe-list
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-04-30 19:25 UTC by Randy Barlow
Modified: 2015-02-28 22:05 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2015-02-28 22:05:28 UTC
Embargoed:


Attachments (Terms of Use)


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

Description Randy Barlow 2014-04-30 19:25:46 UTC
If you start an upload, interrupt it, remove the file you were uploading, and then remove it, pulp-admin will fail ungracefully:

% pulp-admin rpm repo uploads resume
+----------------------------------------------------------------------+
                            Upload Requests
+----------------------------------------------------------------------+
               
Select one or more uploads to resume:
  -  1 : gofer-system-1.0.5-1.el7.noarch.rpm
  -  2 : python-gofer-amqplib-1.0.5-1.el7.noarch.rpm
  -  3 : python-amqp-doc-1.4.4-1.el7.noarch.rpm
  -  4 : d8b6b437-6f50-46ed-a795-f896141de377
  -  5 : ruby-gofer-1.0.5-1.el7.noarch.rpm
  -  6 : python-gofer-1.0.5-1.el7.noarch.rpm
  -  7 : d8b6b437-6f50-46ed-a795-f896141de377
  -  8 : d8b6b437-6f50-46ed-a795-f896141de377
  -  9 : d8b6b437-6f50-46ed-a795-f896141de377
  -  10: python-semantic-version-2.2.0-3.el7.noarch.rpm
  -  11: d8b6b437-6f50-46ed-a795-f896141de377
  -  12: python-kombu-3.0.13-1.pulp.el7.noarch.rpm
  -  13: python-amqp-1.4.4-1.el7.noarch.rpm
  -  14: d8b6b437-6f50-46ed-a795-f896141de377
  -  15: python-simplejson-3.2.0-1.el7.x86_64.rpm
  -  16: gofer-virt-1.0.5-1.el7.noarch.rpm
  -  17: python-celery-3.1.9-1.el7.noarch.rpm
  -  18: d8b6b437-6f50-46ed-a795-f896141de377
  -  19: gofer-package-1.0.5-1.el7.noarch.rpm
  -  20: python-nectar-1.2.1-1.el7.noarch.rpm
  -  21: d8b6b437-6f50-46ed-a795-f896141de377
  -  22: d8b6b437-6f50-46ed-a795-f896141de377
  -  23: python-isodate-0.5.0-1.pulp.el7.noarch.rpm
  -  24: python-requests-2.2.1-1.el7.noarch.rpm
  -  25: gofer-1.0.5-1.el7.noarch.rpm
  -  26: python-gofer-qpid-1.0.5-1.el7.noarch.rpm
  -  27: d8b6b437-6f50-46ed-a795-f896141de377
  -  28: python-requests-2.2.1-1.git.0.3e8cef0.el7.noarch.rpm
  -  29: d8b6b437-6f50-46ed-a795-f896141de377
Enter value (1-29) to toggle selection, 'c' to confirm selections, or '?' for
more commands: 28
               
Select one or more uploads to resume:
  -  1 : gofer-system-1.0.5-1.el7.noarch.rpm
  -  2 : python-gofer-amqplib-1.0.5-1.el7.noarch.rpm
  -  3 : python-amqp-doc-1.4.4-1.el7.noarch.rpm
  -  4 : d8b6b437-6f50-46ed-a795-f896141de377
  -  5 : ruby-gofer-1.0.5-1.el7.noarch.rpm
  -  6 : python-gofer-1.0.5-1.el7.noarch.rpm
  -  7 : d8b6b437-6f50-46ed-a795-f896141de377
  -  8 : d8b6b437-6f50-46ed-a795-f896141de377
  -  9 : d8b6b437-6f50-46ed-a795-f896141de377
  -  10: python-semantic-version-2.2.0-3.el7.noarch.rpm
  -  11: d8b6b437-6f50-46ed-a795-f896141de377
  -  12: python-kombu-3.0.13-1.pulp.el7.noarch.rpm
  -  13: python-amqp-1.4.4-1.el7.noarch.rpm
  -  14: d8b6b437-6f50-46ed-a795-f896141de377
  -  15: python-simplejson-3.2.0-1.el7.x86_64.rpm
  -  16: gofer-virt-1.0.5-1.el7.noarch.rpm
  -  17: python-celery-3.1.9-1.el7.noarch.rpm
  -  18: d8b6b437-6f50-46ed-a795-f896141de377
  -  19: gofer-package-1.0.5-1.el7.noarch.rpm
  -  20: python-nectar-1.2.1-1.el7.noarch.rpm
  -  21: d8b6b437-6f50-46ed-a795-f896141de377
  -  22: d8b6b437-6f50-46ed-a795-f896141de377
  -  23: python-isodate-0.5.0-1.pulp.el7.noarch.rpm
  -  24: python-requests-2.2.1-1.el7.noarch.rpm
  -  25: gofer-1.0.5-1.el7.noarch.rpm
  -  26: python-gofer-qpid-1.0.5-1.el7.noarch.rpm
  -  27: d8b6b437-6f50-46ed-a795-f896141de377
  x  28: python-requests-2.2.1-1.git.0.3e8cef0.el7.noarch.rpm
  -  29: d8b6b437-6f50-46ed-a795-f896141de377
Enter value (1-29) to toggle selection, 'c' to confirm selections, or '?' for
more commands: c

Resuming upload for: python-requests-2.2.1-1.git.0.3e8cef0.el7.noarch.rpm

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.

Uploading: python-requests-2.2.1-1.git.0.3e8cef0.el7.noarch.rpm
An unexpected error has occurred. More information can be found in the client
log file ~/.pulp/admin.log.

From the admin.log:

2014-04-30 15:14:32,826 - ERROR - Client-side exception occurred
Traceback (most recent call last):
  File "/home/rbarlow/devel/pulp/client_lib/pulp/client/commands/repo/upload.py", line 149, in perform_upload
    upload_manager.upload(upload_id, progress_callback)
  File "/home/rbarlow/devel/pulp/client_lib/pulp/client/upload/manager.py", line 247, in upload
    source_file_size = os.path.getsize(tracker_file.source_filename)
  File "/usr/lib64/python2.7/genericpath.py", line 49, in getsize
    return os.stat(filename).st_size
OSError: [Errno 2] No such file or directory: '/tmp/tito/noarch/python-requests-2.2.1-1.git.0.3e8cef0.el7.noarch.rpm'

Comment 1 Brian Bouterse 2015-02-28 22:05:28 UTC
Moved to https://pulp.plan.io/issues/422


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