Image cannot be displayed because it contains errors

RESOLVED WORKSFORME

Status

()

RESOLVED WORKSFORME
6 years ago
2 years ago

People

(Reporter: 2045singularity, Unassigned)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(3 attachments)

(Reporter)

Description

6 years ago
User Agent: Mozilla/5.0 (Windows NT 5.1; rv:16.0) Gecko/20100101 Firefox/16.0
Build ID: 20121010144125

Steps to reproduce:

There is a bug with Firefox (16.0.1) regarding viewing images. Sometimes FF says images "cannot be displayed because it contains errors." Deleting cookies temporarily fixes the bug. Please fix this bug. It usually happens when the image is view repeatedly for an unknown number of times, for example 5 times is OK, and perhaps 10 times would be OK but around 10 times (or higher) of repeat viewing the bug occurs. The error message FF generates is an error message in the form of an image, here is the screen-shot: http://i.imgur.com/45fTu.png 

Google Chrome and other browsers don't seem to have this problem. The header image has been created and added normally as part of the Blogger platform. Image URL is: http://1.bp.blogspot.com/-PPqVEfC_Ofo/UKv_9BFTQLI/AAAAAAAAFaY/V4nTQNAXgto/s1600/2045blog_utopia.png 

Blog URL is: http://singularity-utopia.blogspot.com   


Actual results:

Firefox will not display image: http://1.bp.blogspot.com/-PPqVEfC_Ofo/UKv_9BFTQLI/AAAAAAAAFaY/V4nTQNAXgto/s1600/2045blog_utopia.png

Image was viewed as part of website: http://singularity-utopia.blogspot.com


Expected results:

Firefox should have displayed image: http://1.bp.blogspot.com/-PPqVEfC_Ofo/UKv_9BFTQLI/AAAAAAAAFaY/V4nTQNAXgto/s1600/2045blog_utopia.png
(Reporter)

Comment 1

6 years ago
Activating InPrivate browsing and then ending InPrivate browsing is another way to temporarily fix the problem without deleting cookies.
(Reporter)

Comment 2

6 years ago
Refreshing on image or the blog does not seem to reproduce the error. In fact it seems very random when the image will refuse to be displayed. I cannot reproduce it at the moment, since starting the Private browsing session, but most assuredly it will happen again. It has been ongoing for at least 3 months.
(Reporter)

Comment 3

6 years ago
Ahh, I have just reproduced the error but I am not exactly sure how. I have a couple of windows open for the same blog and clicked various pages in the blog (a lot of times) but nothing happened, and then for some unknown reason the image became an error.
(Reporter)

Comment 4

6 years ago
I think the error may occur after previewing any unpublished page in Blogger. I have again reproduced the error quicker this time.

Here is the code from the image error page:


<html>
<head>
<meta content="width=device-width; height=device-height;" name="viewport">
<link href="resource://gre/res/TopLevelImageDocument.css" rel="stylesheet">
</link>
<link href="chrome://global/skin/TopLevelImageDocument.css" rel="stylesheet">
</link>
<title>2045blog_utopia.png (PNG Image, 890&nbsp;×&nbsp;320 pixels) - Scaled (30%)
</title>
</head>
<body><img style="cursor: -moz-zoom-in" class="decoded" alt="The image “http://1.bp.blogspot.com/-PPqVEfC_Ofo/UKv_9BFTQLI/AAAAAAAAFaY/V4nTQNAXgto/s1600/2045blog_utopia.png” cannot be displayed because it contains errors." src="http://1.bp.blogspot.com/-PPqVEfC_Ofo/UKv_9BFTQLI/AAAAAAAAFaY/V4nTQNAXgto/s1600/2045blog_utopia.png" height="99" width="275">
</body>
</html>
(Reporter)

Comment 5

6 years ago
I doubt you will be able to reproduce the problem, I often cannot seem to reproduce it but it does exist, please fix it.
It can't be fixed if it can't be reproduced.
Anyway, your browser version is old (we are currently at Firefox17)
(Reporter)

Comment 7

6 years ago
It can be reproduced, I am just not exactly sure of the correct method to reproduce it. Regarding my version of FF being 16, I am sure this is not a problem and 17 would also be buggy too. I will check this soon. I was using 16 because TabMixPlus was incompatible with 16 and if I cannot use TabMixPlus then I have no further need for FF and I may as well use Chrome, which actually could be a good idea.

Hopefully I can soon give you more precise details regarding how to reproduce it.

But in the meantime you must have some idea why FF says an image can't be displayed when it can? What is the "image can't be displayed due errors" about? What is the purpose of such a message? For what circumstances was such a message designed. Why so cryptic, what errors exactly prevents FF from displaying the image?
(Reporter)

Comment 9

6 years ago
I was using 16 because TabMixPlus was incompatible with 17
Does this still happen? The image displayed for me now.
we got no other reports about this (AFAIK) and we don't have reliable steps to reproduce.
marking worksforme, please reopen if you still have this issue
Status: UNCONFIRMED → RESOLVED
Last Resolved: 4 years ago
Resolution: --- → WORKSFORME

Comment 12

4 years ago
Created attachment 8536498 [details]
Nightly 37, Win64 'image can not be displayed because it contains errors' (screenshot #1).png

FF Nightly 37/e10s/Win64 (and prior versions) has hard time showing images at the first attempt, falsely reporting that there are errors in the images (as seen in this screenshot #1), even though there are absolutely no errors (see in screenshot #2 below).

Comment 13

4 years ago
Created attachment 8536499 [details]
Nightly 37, Win64 in reality the image can be displayed, there are no errors (screenshot #2).png

In reality, of course, there are no errors in the images, they are perfectly fine. The trick to force FF into actually showing those images is to close the tab with error, and then revive it back via green basket (restore from closed tabs) -- the result is shown in this screenshot #1: totally working image.

This thing is annoying, it happens in many cases, even on this BugZilla site. Is there a way to kill this bug?
Flags: needinfo?(bugzilla)
Please open a new bug report after you have tested Firefox without addons (safemode)
I can not reproduce the issue at all. You have either a network problem. an addon issue or less likely something is wrong with your firefox profile (disk cache).
Flags: needinfo?(bugzilla)

Comment 15

4 years ago
Matthias, thanks for the prompt. It has turned out that NoScript (latest version 2.6.9.6 and prior) causes this behaviour. When I switch it off, the error goes away, and when I switch it on, it returns. Apparently, it somehow blocks even Mozilla's internal scripts that manage the display of images. 

I have "Add-on Compatibility Reporter 2.0.4" extension activated, but it is useless since in the few latest Nightly versions status bar has take a beating in a way that nothing that have worked via status bar survived. So there is even no good way to report this incompatibility, aside of filing a bug, which could be excessive in this case.

Or maybe there is a way to turn the status bar on? I could not find it in the options.

Comment 16

3 years ago
Created attachment 8652535 [details]
Demo for "cannot be displayed" fferror.jpeg

Noticing the same issue as in the original message with both firefox developer edition 42.0a2 (on Windows 8.1) and Firefox 40.0.2 (Windows 7). The attached image doesn't open with firefox and just returns that "image ... cannot be displayed because it contains errors". Opens fine in IE11 and via image viewers, though. I restarted Firefox in safe-mode, but same occurs, I also tried the swapping to private mode back as suggested earlier in this thread. Also I cleared cookies and cache and restarted browser in between, but no help. Any hints?

Comment 17

3 years ago
The same problem with the Firefox 41.0 (upgraded recently from Firefox 9, which has no such problem)

 The image "https://upload.wikimedia.org/wikipedia/commons/a/a2/Pathfinder_Dam_-_Wyoming.jpg" cannot be displayed because it contains errors.

 History-Clear Recent History-Everything (for cache and cookies) helped only for one day :-( .
MSIE 6 has no problem with images like above.

 Firefox is able to download it (Save link as...) and any image viewer is able to open it, but Firefox not:

The image "file:///D:/Temp/Pathfinder_Dam_-_Wyoming.jpg" cannot be displayed because it contains errors.

(Windows XP)

Comment 18

3 years ago
(In reply to O.B. from comment #17)
> The same problem with the Firefox 41.0 (upgraded recently from Firefox 9,
> which has no such problem)
> 
>  The image
> "https://upload.wikimedia.org/wikipedia/commons/a/a2/Pathfinder_Dam_-
> _Wyoming.jpg" cannot be displayed because it contains errors.
> 
>  History-Clear Recent History-Everything (for cache and cookies) helped only
> for one day :-( .
> MSIE 6 has no problem with images like above.
> 
>  Firefox is able to download it (Save link as...) and any image viewer is
> able to open it, but Firefox not:
> 
> The image "file:///D:/Temp/Pathfinder_Dam_-_Wyoming.jpg" cannot be displayed
> because it contains errors.
> 
> (Windows XP)

I have just upgraded to 41.0.2 and it works just now.

Comment 19

3 years ago
Unfortunately on Windows 7, with 41.0.2, still doesn't work.
(In reply to T. from comment #16)
> Opens fine in IE11 and via image viewers, though.

I couldn't display the image with IE11 on Windows 10. Nor Chrome and Edge.

Comment 21

3 years ago
> I have just upgraded to 41.0.2 and it works just now.

Unfortunately, my conclusion was wrong. It does not work again.

Comment 22

2 years ago
still existing in ff 48 mac on a kind of random base ... ff would show 12 of 20 pictures on a site all treated the same way by myself with Photoshop ...that's really odd
Each picture would have a different reason for not being displayed. If you have an image that is displayed in other browsers but not in Firefox, please file a bug, include the image (or a link to it), and you can cc me (tnikkel@gmail.com) on the bug as well.

Comment 24

2 years ago
(In reply to Timothy Nikkel (:tnikkel) from comment #23)
> Each picture would have a different reason for not being displayed. If you
> have an image that is displayed in other browsers but not in Firefox, please
> file a bug, include the image (or a link to it), and you can cc me
> (tnikkel@gmail.com) on the bug as well.

This bug does not depend on picture. Sometimes Firefox shows the picture, sometimes not. Probably depends on some buffer fill or cache fill or what. Mostly big pictures originate this problem. The Firefox's message is misleading, the picture surely does not contain any errors. As I wrote before, I have problem for instance with this picture: "https://upload.wikimedia.org/wikipedia/commons/a/a2/Pathfinder_Dam_-_Wyoming.jpg" Just now Firefox shows it. Sometimes say " The image "https://upload.wikimedia.org/wikipedia/commons/a/a2/Pathfinder_Dam_-_Wyoming.jpg" cannot be displayed because it contains errors." As soon as this happen, almost all big pictures "contains errors". Restart helps for a while.
(Firefox 41.0.2)

Comment 25

2 years ago
@ Tomothy & @ O.B. 
high, 
in general I'm with O.B. ... 
Though I didn't invest much time on the case when I checked that the pix showed correctly in all other browsers. Fist I tried with recreating and exchanging the concerned pix with no better results ...  then I updated my system to FF 49 (mac) and the issue was gone for now. 
Only here after quickly researching for solutions I saw that the issue has a history and ...

Comment 26

2 years ago
What can be said so far:
1. the issue is very old, lasts for years;
2. I still stumble upon it occasionally;
3. never experienced it in other browsers, they were able show the very same pictures just fine in all cases I tried;
4. it seems that it will be never fixed.

Comment 27

2 years ago
I may have found a way to reproduce this consistently.

- Sign up for Digg Reader (https://digg.com/reader)
- Subscribe to any subreddit with lots of imgur links, or the entire domain. (https://www.reddit.com/domain/imgur.com/.rss)
- Let it sit until it has a few new items in the feed.
- Ctrl + Click the [link] in the post. Note that this only works with direct links.

Apparently it works just fine when you initially subscribe. Try marking all items as read in Digg Reader, and sign back in after 5 minutes to see new items in the feed.

This has been plaguing me on three instances of Firefox - two instances on Windows 10, and one on Arch Linux. Was a non issue three or four versions ago.
If you see this come up when you have lots of images around then it's likely because there is a limit to the amount of image data we will keep around decoded. That limit is calculated as the minimum of

"amount of memory"/pref(image.mem.surfacecache.size_factor)

and

pref(image.mem.surfacecache.max_size_kb)

image.mem.surfacecache.max_size_kb is set to 1GB by default, and image.mem.surfacecache.size_factor is 4 by default. So any machine with >= 4GB of ram will have 1GB. You can check how much memory is being used by images (and which ones) by looking at about:memory. Note that we will likely discard images in background tabs, so open about:memory in a new window otherwise the images in the current tab that are likely causing the high memory will be discarded.

Comment 29

2 years ago
@ timothy

got that ... but it would be an explication only if it would happen on a regular basis. Is it possible that
this kind of memory allocation is cumulating when it should not ?
On the other hand it would not explain the fact that, if it occurs it's always the same pix which do not show up ... until you reinstall or update FF
(In reply to Micky from comment #29)
> Is it possible that
> this kind of memory allocation is cumulating when it should not ?

Yes, if we are holding on to too many images (that we shouldn't be) then we would want to investigate that. You can use about:memory to help you determine if this is the case.

> On the other hand it would not explain the fact that, if it occurs it's
> always the same pix which do not show up ... until you reinstall or update FF

If one image never shows up, even after restarting that would be a different bug, and yes we would also want to understand and fix that issue. We would need more details in order to move forward on that.
You need to log in before you can comment on or make changes to this bug.