Bug 555677

Summary: REF - logfile attachments get mimetype of plain/x-log instead of plain/text
Product: [Community] Bugzilla Reporter: Hans de Goede <hdegoede>
Component: Attachments/RequestsAssignee: Simon Green <sgreen>
Status: CLOSED DUPLICATE QA Contact:
Severity: high Docs Contact:
Priority: high    
Version: develCC: collura, ebaak, kbaker, LpSolit, mcepl, sgreen
Target Milestone: ---Keywords: Reopened
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-05-21 08:24:23 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Hans de Goede 2010-01-15 07:37:01 UTC
Description of problem:
logfile attachments get mimetype of plain/x-log instead of plain/text

Steps to Reproduce:
1. Attach a foo.log file to a bug report, leave the type set to auto.
  
Actual results:
The attachment has a mimetype of plain/x-log, clicking on it results in a save as
dialog

Expected results:
The attachment has a mimetype of plain/text, clicking on it shows it.

Comment 1 Noura El hawary 2010-01-15 12:02:00 UTC
This is not a new behavior after the upgrade, .log attachments were always set as text/x-log for auto detect option, however you can manually set it at creation time to be plain/text and that will work as per your requirement. I don't think we will be looking at changing this normal behavior as this is how it works in the upstream bugzilla, and we need to stick to the upstream bugzilla as much as possible and avoid unnecessary customizations.

Regards,
Noura

Comment 2 Hans de Goede 2010-01-15 12:38:55 UTC
(In reply to comment #1)
> This is not a new behavior after the upgrade, .log attachments were always set
> as text/x-log for auto detect option, however you can manually set it at
> creation time to be plain/text and that will work as per your requirement. I
> don't think we will be looking at changing this normal behavior as this is how
> it works in the upstream bugzilla, and we need to stick to the upstream
> bugzilla as much as possible and avoid unnecessary customizations.
> 

That is not true, in the old bugzilla the mimetype got set to application/octet-stream. IOW the autodetect option did not recognise it at all. Now that it does recognise log files as such, it should give them a usable mimetype.

Regards,

Hans

Comment 3 Noura El hawary 2010-01-18 13:56:24 UTC
Okay then we will consider this a feature request, that maybe we can look into in the future.

Regards,
Noura

Comment 4 Hans de Goede 2010-06-07 08:59:54 UTC
Can we please please have this fixed. I've been doing bug triage today and needed to change a dozen or more attachment mime types from plain/x-log to plain/text.

Fixing this sure ain't rocket science and the bug is very disruptive to our workflow. Doing click log attachment get, save as dialog, click cancel. Edit details, click attachment again. Dozens times a day really is a problem.

Comment 5 Frédéric Buclin 2011-02-20 10:19:28 UTC
The MIME type is set by your web browser, not by Bugzilla itself. This means that your browser didn't detect your file as text/plain, but as text/x-log.

Comment 6 Matěj Cepl 2012-05-21 07:30:36 UTC
Probably a duplicate of bug 618713

Comment 7 Simon Green 2012-05-21 08:24:23 UTC
(In reply to comment #6)
> Probably a duplicate of bug 618713

No objection from me.

*** This bug has been marked as a duplicate of bug 618713 ***