Uploaded image for project: 'Jira Data Center'
  1. Jira Data Center
  2. JRASERVER-20072

Attachment and thumbnail missing in issue when CMYK jpeg image attached.

      NOTE: This bug report is for JIRA Server. Using JIRA Cloud? See the corresponding bug report.

      The thumbnail is not generated, and also the attachment does not appear in the attachments list when a CMYK JPEG image is attached to an issue due to the following exception during the ImageIO parsing:

      javax.imageio.IIOException: Unsupported Image Type
      at com.sun.imageio.plugins.jpeg.JPEGImageReader.readInternal(JPEGImageReader.java:940)
      at com.sun.imageio.plugins.jpeg.JPEGImageReader.read(JPEGImageReader.java:915)
      at javax.imageio.ImageIO.read(ImageIO.java:1422)
      at javax.imageio.ImageIO.read(ImageIO.java:1326)
      at com.atlassian.core.util.thumbnail.Thumber.getImage(Thumber.java:281)
      at com.atlassian.core.util.thumbnail.Thumber.createThumbnail(Thumber.java:241)
      at com.atlassian.core.util.thumbnail.Thumber.retrieveOrCreateThumbNail(Thumber.java:215)
      at com.atlassian.core.util.thumbnail.Thumber.retrieveOrCreateThumbNail(Thumber.java:86)
      .....

        1. cmyk.jpg
          cmyk.jpg
          874 kB
        2. CMYK JPEG - No Color Profile Error
          214 kB
        3. SourceProfileTest_CMYK_5percent-en.jpg
          SourceProfileTest_CMYK_5percent-en.jpg
          3.79 MB

            [JRASERVER-20072] Attachment and thumbnail missing in issue when CMYK jpeg image attached.

            Aqqiela added a comment -

            This is reproducible in JIRA 6.3.15 and 6.4.X. However, this is obsolete in JIRA 7 (not reproducible).

            Aqqiela added a comment - This is reproducible in JIRA 6.3.15 and 6.4.X. However, this is obsolete in JIRA 7 (not reproducible).

            I've investigated new image types and I've found two issues:

            1. https://jira.atlassian.com/browse/CORE-185 - When CMYK image hasn't embedded ICCProfile Thumber couldn't load that image.

            2. https://jira.atlassian.com/browse/CORE-186 - Known JDK bug: http://bugs.sun.com/view_bug.do?bug_id=4884308

            I've fixed both issues in altassian-core 4.6.10 and added it to JIRA (stable and master).

            Additional information for 2.: I've implemented a workaround which displays thumbnail in gray colors (instead of not displaying them at all).

            Przemyslaw Borkowski (Inactive) added a comment - I've investigated new image types and I've found two issues: 1. https://jira.atlassian.com/browse/CORE-185 - When CMYK image hasn't embedded ICCProfile Thumber couldn't load that image. 2. https://jira.atlassian.com/browse/CORE-186 - Known JDK bug: http://bugs.sun.com/view_bug.do?bug_id=4884308 I've fixed both issues in altassian-core 4.6.10 and added it to JIRA (stable and master). Additional information for 2.: I've implemented a workaround which displays thumbnail in gray colors (instead of not displaying them at all).

            For QA review when this comes back again we will need design (CC: rchaldecott) to provide us with the CMYK JPEGS using the following profiles:

            US Web Coated (SWOP) v2
            US Web Uncoated v2
            US Sheetfed Coated v2
            US Sheetfed Uncoated v2
            Coated FOGRA27 (ISO 12647-2:2004)
            Web Coated FOGRA28 (ISO 12647-2:2004)
            Uncoated FOGRA29 (ISO 12647-2:2004)
            Coated FOGRA39 (ISO 12647-2:2004)
            Japan Web Coated (Ad)
            Japan Color 2001 Coated
            Japan Color 2001 Uncoated
            Japan Color 2002 Newspaper

            We will also use the two other CMYK JPEGS including the one with no embedded profile that has prompted us to put this back to in progress.

            Oswaldo Hernandez (Inactive) added a comment - For QA review when this comes back again we will need design (CC: rchaldecott ) to provide us with the CMYK JPEGS using the following profiles: US Web Coated (SWOP) v2 US Web Uncoated v2 US Sheetfed Coated v2 US Sheetfed Uncoated v2 Coated FOGRA27 (ISO 12647-2:2004) Web Coated FOGRA28 (ISO 12647-2:2004) Uncoated FOGRA29 (ISO 12647-2:2004) Coated FOGRA39 (ISO 12647-2:2004) Japan Web Coated (Ad) Japan Color 2001 Coated Japan Color 2001 Uncoated Japan Color 2002 Newspaper We will also use the two other CMYK JPEGS including the one with no embedded profile that has prompted us to put this back to in progress.

            The CMYK image provided works now. However, testing revealed that an image if the image is in CMYK color space AND it doesn't have a color profile it fails to be loaded. I have attached a test image to the issue and full output of logs.

            Oswaldo Hernandez (Inactive) added a comment - The CMYK image provided works now. However, testing revealed that an image if the image is in CMYK color space AND it doesn't have a color profile it fails to be loaded. I have attached a test image to the issue and full output of logs.

            Waiting for review in CORE-168

            Przemyslaw Borkowski (Inactive) added a comment - Waiting for review in CORE-168

            mdm added a comment -

            hi,
            Can you fix it as soon as possible?
            It's a big issue for us because graphist can't see the picture and need to download many picture to find the good one.

            mdm added a comment - hi, Can you fix it as soon as possible? It's a big issue for us because graphist can't see the picture and need to download many picture to find the good one.

            Ramon Grunder added a comment - this might fix the issue for gray-scale images: http://stackoverflow.com/questions/10416378/imageio-read-illegal-argument-exception-raster-bands-colour-space-components

            We just came across the same issue in my company too. In our case the error shown is the one described in JRA-26615 with the java.lang.IllegalArgumentException: Numbers of source Raster bands and source color space components do not match message.

            Marsha Brändle added a comment - We just came across the same issue in my company too. In our case the error shown is the one described in JRA-26615 with the java.lang.IllegalArgumentException: Numbers of source Raster bands and source color space components do not match message.

            We have come across this bug at my company - as we make graphic design packages it is not uncommon for CMYK JPEGs to be attached to our issues.

            Sarah Woodhouse added a comment - We have come across this bug at my company - as we make graphic design packages it is not uncommon for CMYK JPEGs to be attached to our issues.

            Ben Still added a comment -

            This is a problem we've hit a few times. The problem is that there isn't any way for a user to know that an issue has one of these attachments. Is there any way that filename can appear - even if the thumbnail creation process fails?

            Ben Still added a comment - This is a problem we've hit a few times. The problem is that there isn't any way for a user to know that an issue has one of these attachments. Is there any way that filename can appear - even if the thumbnail creation process fails?

              jhazelwood James Hazelwood
              astuckey Adam Stuckey [Atlassian]
              Affected customers:
              17 This affects my team
              Watchers:
              23 Start watching this issue

                Created:
                Updated:
                Resolved: