Addressables build issue

Hi there,

I’m currently developing a multiplayer game and I’m using addressables in my project. Today I’ve run into an issue which I can’t seem to shake, which is the following:

Cannot read BuildLayout header, BuildLayout has not open for a file
UnityEditor.AddressableAssets.Settings.AddressableAssetSettings:BuildPlayerContent (UnityEditor.AddressableAssets.Build.AddressablesPlayerBuildResult&)
AddressablesPlayerBuildProcessor:PrepareForPlayerbuild (UnityEditor.AddressableAssets.Settings.AddressableAssetSettings,UnityEditor.Build.BuildPlayerContext,bool) (at ./Library/PackageCache/com.unity.addressables@1.21.12/Editor/Build/AddressablesPlayerBuildProcessor.cs:101)
AddressablesPlayerBuildProcessor:PrepareForBuild (UnityEditor.Build.BuildPlayerContext) (at ./Library/PackageCache/com.unity.addressables@1.21.12/Editor/Build/AddressablesPlayerBuildProcessor.cs:80)
UnityEditor.EditorApplication:Internal_CallGlobalEventHandler ()

This stops me from being able to build my project. What I’ve tried:

  • Clearing the cache
  • Deleting the addressablesAssetData folder
  • Doing a new addressables build

None of these steps have worked. As this is a multiplayer game, the only way I can really test it is by creating builds so this has stopped me in my tracks a fair bit. Any help would be greatly appreciated.

I’m using Unity v2022.3.0 and using addressables v1.21.12.

1 Like

This may have been some weird data in a previous build that was still interfering with current builds. I tried a clean build from the build menu in Unity and it is seemingly back to normal.

1 Like

I have the same issue. Can you explain what you mean by a clean build from the unity menu.

1 Like

Thank you very much!!
I annoyed same matter, and solved clean build!!

@radiantboy

maybe clean build in build menu.
Please click small triangle next to Build button in Build Settings window.

3 Likes

I have a clean build and still have this error. Any other suggestions?

Cannot read BuildLayout header, BuildLayout has not open for a file
UnityEditor.AddressableAssets.Settings.AddressableAssetSettings:BuildPlayerContent (UnityEditor.AddressableAssets.Build.AddressablesPlayerBuildResult&)
AddressablesPlayerBuildProcessor:PrepareForPlayerbuild (UnityEditor.AddressableAssets.Settings.AddressableAssetSettings,UnityEditor.Build.BuildPlayerContext,bool) (at ./Library/PackageCache/com.unity.addressables@1.21.12/Editor/Build/AddressablesPlayerBuildProcessor.cs:101)
AddressablesPlayerBuildProcessor:PrepareForBuild (UnityEditor.Build.BuildPlayerContext) (at ./Library/PackageCache/com.unity.addressables@1.21.12/Editor/Build/AddressablesPlayerBuildProcessor.cs:80)
UnityEditor.BuildPlayerWindow/DefaultBuildMethods:BuildPlayer (UnityEditor.BuildPlayerOptions)
Naninovel.BuildProcessor:BuildPlayer (UnityEditor.BuildPlayerOptions) (at Assets/Naninovel/Editor/Build/BuildProcessor.cs:46)
UnityEngine.GUIUtility:ProcessEvent (int,intptr,bool&)
9 Likes

I’m following the solution from this article and it work for me: https://marumaro7.hatenablog.com/entry/CannotreadBuildLayoutheader
Which is delete file “AddressablesConfig.dat” from Library folder, then restart Editor.

I just fixed this by closing the ‘Addressables report’ window, looks like it being open is causing this to happen.

8 Likes

Thank you, this fixed the issue quickly. I’ve been fixing it in a more tedious way which i found out by luck, it goes by running analyze selected rule, change the script a little for it to recompile, then build it. with no other action in between. The non-sensical sequence was quite worrying.

No freaking way… this worked for me. Now, how to get rid of this window permanently? It keeps reappearing.
Edit: It’s in Preferences > Addressables

Yup. Disabling the build report window is here in the Preferences window:

Would y’all mind letting me know what versions of Addressables and Unity you’re using? I can’t seem to reproduce the issue.

Thank you so MUCH! I just docked mine so I didn’t have to keep closing it to get it out of the way!! I never would have thought of that :open_mouth: