Issue with Importing 4.3 Project

Godot Version

v4.3.stable.official [77dcf97d8]

Question

I have been working on a project in Godot for about a week now. The original project works very well, however when I try to clone the repository using the same version, I get the following errors like these on import:

 res://screenreader/menu/base_menu.gd:22 - Parse Error: Preload file "res://screenreader/ui/img/default/x_box.png" has no resource loaders (unrecognized file extension).
  res://screenreader/menu/base_menu.gd:23 - Parse Error: Preload file "res://screenreader/ui/img/dark/x_box.png" has no resource loaders (unrecognized file extension).
  res://screenreader/menu/base_menu.gd:24 - Parse Error: Preload file "res://screenreader/ui/img/light/x_box.png" has no resource loaders (unrecognized file extension).
  modules/gdscript/gdscript.cpp:2936 - Failed to load script "res://screenreader/menu/base_menu.gd" with error "Parse error". (User)
  scene/resources/resource_format_text.cpp:453 - res://screenreader/ui/style/Access.tres:3 - ext_resource, invalid UID: uid://crvj8qlrx0te2 - using text path instead: res://screenreader/ui/img/dark/checkbox_ticked.png
  No loader found for resource: res://screenreader/ui/img/dark/checkbox_ticked.png (expected type: Texture2D)
  scene/resources/resource_format_text.cpp:453 - res://screenreader/ui/style/Access.tres:4 - ext_resource, invalid UID: uid://dohwt7eehgkga - using text path instead: res://screenreader/ui/img/dark/checkbox_disabled_ticked.png
  No loader found for resource: res://screenreader/ui/img/dark/checkbox_disabled_ticked.png (expected type: Texture2D)
  scene/resources/resource_format_text.cpp:453 - res://screenreader/ui/style/Access.tres:5 - ext_resource, invalid UID: uid://ipepesuwgsjo - using text path instead: res://screenreader/ui/img/dark/radio_button_on.png
  No loader found for resource: res://screenreader/ui/img/dark/radio_button_on.png (expected type: Texture2D)
  scene/resources/resource_format_text.cpp:453 - res://screenreader/ui/style/Access.tres:6 - ext_resource, invalid UID: uid://dudp4udv21362 - using text path instead: res://screenreader/ui/img/dark/radio_button_disabled_on.png
  No loader found for resource: res://screenreader/ui/img/dark/radio_button_disabled_on.png (expected type: Texture2D)
  scene/resources/resource_format_text.cpp:453 - res://screenreader/ui/style/Access.tres:7 - ext_resource, invalid UID: uid://b7p2ddyx8ingw - using text path instead: res://screenreader/ui/img/dark/radio_button_off.png
  No loader found for resource: res://screenreader/ui/img/dark/radio_button_off.png (expected type: Texture2D)
  scene/resources/resource_format_text.cpp:453 - res://screenreader/ui/style/Access.tres:8 - ext_resource, invalid UID: uid://gysfc2ln7t11 - using text path instead: res://screenreader/ui/img/dark/radio_button_disabled_off.png
  No loader found for resource: res://screenreader/ui/img/dark/radio_button_disabled_off.png (expected type: Texture2D)
  scene/resources/resource_format_text.cpp:453 - res://screenreader/ui/style/Access.tres:9 - ext_resource, invalid UID: uid://c235iu268rqw - using text path instead: res://screenreader/ui/img/dark/checkbox_unticked.png
  No loader found for resource: res://screenreader/ui/img/dark/checkbox_unticked.png (expected type: Texture2D)

It appears to be concentrated around .wav files I am using in the project. I have no idea what is causing this to happen though.

So you have missing files with perhaps invalid extensions, as well as invalid resources types. This looks to me like it was last edited in a different version of Godot.

First thing to do is check you are opening the right version with all the latest assets and resources.

Next, check the files exist and have the correct extensions. Then allow the project to open and re-import the missing assets.

Finally, you can try deleting the root .godot folder and force everything to be re-imported.

Hope you get it fixed and this helps in some way.

Edit: The first error was weird though as it is clearly looking for a png. It might also be that the png file is corrupted in some way, so you could try replacing these images with fresh copies too.

Errors appear only when the project is opened for the first time. Only non-critical warnings are displayed when opening the project afterwards. The functionality is not affected. Possible problems (reasons for displaying errors) in the engine itself.

Sadly this is not what is happening.

  1. The version created in was the same exact version (same ID number) as the one it was pulled in. It happens in both Windows and Linux, so it does not appear to be platform-dependent.

  2. The file extensions are “.wav” and “.png”, which should both be valid filetypes. They also work in the native OS, so the files aren’t corrupted.

  3. There are no extensions in use. Only a few Global scripts assigned.

Based on meddling in the last few days, it appears that tomcat’s answer is correct, but this is unfortunate, since I need to write a warning on my documentation to re-open the project, since theme styles with references to image assets will break if the user interacts with the project files when the project is opened for the first time. The project is used as a template for people who want to start building their game with the asset, so this really sucks.

What appears to be happening is that Godot reads the project file and imports the files after the initial script parsing is done, which leads to script and reference errors. It’s not until a second reload that the references are correct, so interacting with any references to these un-imported files leads to bugs in the project, such as theme styles losing references to their images.

Should I report this as an issue on the issue tracker? I don’t understand why Godot isn’t checking if .import assets actually exist before trying to parse the script files.

2 Likes

A similar problem occurs with other formats. Godot regularly informs me that it doesn’t know .gltf, even in a local project on my computer. So I guess the problem is deeper than that, but you can try to report the issue.