It is currently July 14th, 2024, 2:21 pm

[Bug] Rainmeter trying to open a non existent png file that hasn't been called

Report bugs with the Rainmeter application and suggest features.
User avatar
eclectic-tech
Rainmeter Sage
Posts: 5453
Joined: April 12th, 2012, 9:40 pm
Location: Cedar Point, Ohio, USA

Re: [Bug] Rainmeter trying to open a non existent png file that hasn't been called

Post by eclectic-tech »

Jaime Méndez wrote: March 29th, 2023, 12:43 pm Thank you for your response, but I still don't understand why my code is still warning for missing png file after doing a code deep clean up, I couldn't find any instruction for such an operation. Skin is much faster an smooth now than posted here down those days when first post.

You can check it out the latest version if you want: https://forum.rainmeter.net/viewtopic.php?t=41394
As Yincognito pointed out, this is due to a change in how Rainmeter handles images. This happens regularly with weather skins that display condition images before the Webparser measures obtain the necessary data.

EDIT: This will not help in your case, since it is happening when you access multiple folders and placing this image in every folder is not an option.

If the error message refers to .png file as missing, one option that will prevent the log messages, is to create a blank .png file in the folder that Rainmeter is reporting the error.

Here is a blank file you can save as ".png" to prevent the error messages:
You do not have the required permissions to view the files attached to this post.
User avatar
Yincognito
Rainmeter Sage
Posts: 7723
Joined: February 27th, 2015, 2:38 pm
Location: Terra Yincognita

Re: [Bug] Rainmeter trying to open a non existent png file that hasn't been called

Post by Yincognito »

Jaime Méndez wrote: March 29th, 2023, 12:43 pmThank you for your response, but I still don't understand why my code is still warning for missing png file after doing a code deep clean up, I couldn't find any instruction for such an operation.
From my experiance, this could happen in one or both of these two cases:
- if the image for a valid image path doesn't exist
- if the path for such an image is not valid
For the first variant, eclectic-tech already provided a solution.
For the second variant, the issue is a bit more complex. It could be because the said path is not yet initialized in the code at the time of access (e.g. a blank variable, etc.), the said path is not properly set up in the code at the time of access (e.g. the variable holding the path parses to an unresolved formula, some other unresolved variables that are not yet set up properly, etc.), or the said path is set up properly only after the time of access (e.g. the need of access happens earlier than you get the chance to set up the path, etc). By "access" I mean the moment when the meter actually wants to read the image specified by the path.

As for debugging, you know best what exactly happens in the code when you click a folder / icon (because it's then that the errors are listed in the log) , but some relatively easy way to help you with the issue would be to just !Log the value of the image path / name option you're using to diplay such images, e.g.:

Code: Select all

[SomeImage]
Meter=Image
ImageName=#@##SomeOtherVariable#.png
OnUpdateAction=[!Log "#@##SomeOtherVariable#.png"]
DynamicVariables=...
Basically, if such a !Log doesn't list a valid path to be used (e.g. "C:\SomeFolder\SomeImage.SomeImageExtension") and instead lists other invalid variants (e.g. ".png" or "#SomeUnresolvedVariable(s)#" or "(1+#SomeVariableInAnUresolvedFormula#)" and so on), then you know you have to fix it one way or another.
Profiles: Rainmeter ProfileDeviantArt ProfileSuites: MYiniMeterSkins: Earth
User avatar
Jaime Méndez
Posts: 98
Joined: August 31st, 2022, 10:00 pm

Re: [Bug] Rainmeter trying to open a non existent png file that hasn't been called

Post by Jaime Méndez »

Yincognito wrote: March 29th, 2023, 7:52 pm For the first variant, eclectic-tech already provided a solution.
I think first variant may be the case, but the problem is that I'd have to place an empty file in all PC directories and subdirectories in order to get rid of the bug. The Skin is a directory browser that reads files and folders everywhere and represents its icon files and thumbnails pictures.
The path certainly exists since no subdirectory is created by the time skin is browsing directories and subdirectories.