Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Linux build error "retrieve: program binary cache file is corrupted. Ignoring and removing." #92140

Open
elvisish opened this issue May 20, 2024 · 4 comments

Comments

@elvisish
Copy link

elvisish commented May 20, 2024

Tested versions

3.5.3.stable

System information

Linux Mint Cinnamon

Issue description

I'm getting an error retrieve: program vinary cache file is corrupted. Ignoring and removing. when I test my level in Linux, this error does not occur at all in Windows, and I can't actually find any information about this error message outside of it appearing in the debug window. It happens several times so I assume it's occurring for each and every shader I'm using in my scene. Here's the full error:

E 0:00:15.373   retrieve: Program binary cache file is corrupted. Ignoring and removing.
  <C++ Source>  drivers/gles3/shader_cache_gles3.cpp:74 @ retrieve()

Steps to reproduce

Run game in Linux.

Minimal reproduction project (MRP)

N/A

@elvisish elvisish changed the title Linux build error "retrieve: program vinary cache file is corrupted. Ignoring and removing." Linux build error "retrieve: program binary cache file is corrupted. Ignoring and removing." May 20, 2024
@AThousandShips AThousandShips added this to the 3.x milestone May 20, 2024
@lawnjelly
Copy link
Member

You also mentioned in a message that this was occurring on SteamDeck, which could be relevant.

It doesn't seem to occur for me (Linux Mint) running the same project.

I am wondering whether it could be a permissions issue (but I'm surprised then that fa isn't returning false, but whether it is using the bool operator I'm not sure, it would be nice to debug):

	FileAccessRef fa = FileAccess::open(storage_path.plus_file(p_program_hash), FileAccess::READ_WRITE);
	if (!fa) {
		return false;
	}

	*r_format = fa->get_32();
	uint32_t binary_len = fa->get_32();
	if (binary_len <= 0 || binary_len > 0x10000000) {
		ERR_PRINT("Program binary cache file is corrupted. Ignoring and removing.");
		fa->close();
		storage_da->remove(p_program_hash);
		return false;
	}

@AThousandShips
Copy link
Member

It might be that it doesn't check for permissions correctly when using READ_WRITE

@lawnjelly
Copy link
Member

Also MRP is always useful, even if it's a basic project, just to eliminate other possible causes in a complex program. Especially as in this case it may be difficult to reproduce.

@elvisish
Copy link
Author

Also MRP is always useful, even if it's a basic project, just to eliminate other possible causes in a complex program. Especially as in this case it may be difficult to reproduce.

I know, I'll see if I can cut down my project into the basics for testing.

It might be that it doesn't check for permissions correctly when using READ_WRITE

Is it possible to change this for testing?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants