Project

Profile

Help

Issue #2543

closed

RPM Importer swallows exception when one is raised during upload

Added by dalley almost 8 years ago. Updated over 5 years ago.

Status:
CLOSED - CURRENTRELEASE
Priority:
Normal
Assignee:
Sprint/Milestone:
-
Start date:
Due date:
Estimated time:
Severity:
2. Medium
Version:
Platform Release:
2.13.0
OS:
Triaged:
Yes
Groomed:
No
Sprint Candidate:
No
Tags:
Pulp 2
Sprint:
Sprint 15
Quarter:

Description

Originally written by , recreated after I accidentally deleted the issue

When uploading an invalid rpm, you get a generic error message: "The importer yum_importer indicated a failed response when uploading rpm unit to repository zoolander." I'd expect some sort of error message about the rpm being invalid instead. Even something like the message logged in journalctl would suffice (ie "error reading package header").

Steps to reproduce:

touch meerkat-2.1.0.noarch.rpm
pulp-admin rpm repo uploads rpm  -f meerkat-2.1.0.noarch.rpm --repo-id zoolander

Related issues

Related to Puppet Support - Issue #2512: Puppet Importer swallows exception when one is raised during uploadCLOSED - CURRENTRELEASEdaviddavisActions
Related to RPM Support - Refactor #2614: Allow PulpCodedException to propagate during upload to relay error informationCLOSED - WONTFIX

Actions
Related to Pulp - Issue #3072: Too generic "The importer yum_importer indicated a failed response"CLOSED - WONTFIXActions
Related to Pulp - Issue #3090: Uploading an invalid rpm produces an error message: "unexpected error occurred importing uploaded file: 'primary'"CLOSED - CURRENTRELEASEjortel@redhat.comActions
Actions #1

Updated by dalley almost 8 years ago

When I test this, I do get such an error message (it's logged before the traceback instead of after, so it is not as prominent and easy to miss).

Jan 24 21:37:01 dev.example.com pulp[4444]: pulp_rpm.plugins.importers.yum.upload:ERROR: [a087e7b5] (4444-63232) Error extracting RPM metadata for [/var/lib/pulp/uploads/30820126-11c3-4dfe-a585-67b7fa68cbeb]

I do think this message is still overly vague and technical, and could be improved a lot. I think we could also pass the information about the cause of the failure from where it is first logged and include it in the later error message that you've pointed out in the description.

Actions #2

Updated by dalley almost 8 years ago

  • Related to Issue #2512: Puppet Importer swallows exception when one is raised during upload added
Actions #3

Updated by daviddavis almost 8 years ago

dalley that works. As long as the pulp-admin user sees a specific error messages besides "The importer yum_importer indicated a failed response..." without having to look in the log files.

Also, another thing to consider: we'll want to make sure that the actual error is being passed back in the api (this might already be the case) so Katello for instance can pass this on to their users.

Actions #4

Updated by dalley almost 8 years ago

  • Sprint/Milestone set to 32
Actions #5

Updated by bmbouter almost 8 years ago

+1 to having a good error message be shown to the user via the API and pulp-admin. I believe this is as simple as raising an exception. The message of the exception will be stored on the TaskStatus. I think that happens here. These "exception swalling" issues I think are mainly fatal errors that should raise an Exception but don't.

The main issue with "fixing" these issues is that there could be important code that would not get run and that could cause behavioral backwards incompatabilities. So that is something to consider. @dkliban and mhrivnak are also well versed in these things topics.

Note that I think this is about the exception being unraised or a fatal exception being treated as a non-fatal exception which causes pulp-admin to not receive the errors and instead it shows success. The error message and logging could be improved, but that would be an additional improvement on top of the primary goal. I could be wrong about this interpretation from the original report, but I wanted to post some thoughts.

Actions #7

Updated by mhrivnak almost 8 years ago

  • Sprint/Milestone changed from 32 to 33
Actions #8

Updated by ipanova@redhat.com almost 8 years ago

  • Project changed from Pulp to RPM Support
Actions #9

Updated by daviddavis almost 8 years ago

  • Status changed from NEW to ASSIGNED
  • Assignee set to daviddavis
Actions #10

Updated by daviddavis almost 8 years ago

  • Status changed from ASSIGNED to NEW
  • Assignee deleted (daviddavis)

Unassigning this to myself since I am leaving tomorrow for vacation.

Actions #11

Updated by fdobrovo almost 8 years ago

  • Status changed from NEW to ASSIGNED
  • Assignee set to fdobrovo
Actions #12

Updated by fdobrovo almost 8 years ago

  • Status changed from ASSIGNED to POST

Added by fdobrovo almost 8 years ago

Revision 7321d9f0 | View on GitHub

2543 - upload isn't showing whole error

closes #2543 https://pulp.plan.io/issues/2543

Actions #13

Updated by fdobrovo almost 8 years ago

  • Status changed from POST to MODIFIED
Actions #14

Updated by daviddavis almost 8 years ago

  • Related to Refactor #2614: Allow PulpCodedException to propagate during upload to relay error information added
Actions #15

Updated by semyers over 7 years ago

  • Platform Release set to 2.13.0
Actions #16

Updated by pcreech over 7 years ago

  • Status changed from MODIFIED to 5
Actions #17

Updated by pcreech over 7 years ago

  • Status changed from 5 to CLOSED - CURRENTRELEASE
Actions #18

Updated by daviddavis about 7 years ago

  • Related to Issue #3072: Too generic "The importer yum_importer indicated a failed response" added
Actions #19

Updated by daviddavis about 7 years ago

  • Related to deleted (Issue #3072: Too generic "The importer yum_importer indicated a failed response")
Actions #20

Updated by daviddavis about 7 years ago

  • Related to Issue #3072: Too generic "The importer yum_importer indicated a failed response" added
Actions #21

Updated by daviddavis about 7 years ago

  • Related to Issue #3090: Uploading an invalid rpm produces an error message: "unexpected error occurred importing uploaded file: 'primary'" added
Actions #22

Updated by bmbouter over 6 years ago

  • Sprint set to Sprint 15
Actions #23

Updated by bmbouter over 6 years ago

  • Sprint/Milestone deleted (33)
Actions #24

Updated by bmbouter over 5 years ago

  • Tags Pulp 2 added

Also available in: Atom PDF